Skip to content

Commit 194513b

Browse files
committed
refactor(registry): remove local_ad model configuration
- Removed the 'local_ad' model configuration from the model registry - This change affects the ModelConfig map in model_registry.dart
1 parent 61e9fa6 commit 194513b

File tree

1 file changed

+0
-30
lines changed

1 file changed

+0
-30
lines changed

lib/src/registry/model_registry.dart

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -425,36 +425,6 @@ final modelRegistry = <String, ModelConfig<dynamic>>{
425425
requiresAuthentication: true,
426426
),
427427
),
428-
'local_ad': ModelConfig<LocalAd>(
429-
fromJson: LocalAd.fromJson,
430-
getId: (ad) => ad.id,
431-
getOwnerId: null, // LocalAd is a global resource, not user-owned
432-
getCollectionPermission: const ModelActionPermission(
433-
type: RequiredPermissionType.specificPermission,
434-
permission: Permissions.localAdRead,
435-
requiresAuthentication: true,
436-
),
437-
getItemPermission: const ModelActionPermission(
438-
type: RequiredPermissionType.specificPermission,
439-
permission: Permissions.localAdRead,
440-
requiresAuthentication: true,
441-
),
442-
postPermission: const ModelActionPermission(
443-
type: RequiredPermissionType.adminOnly,
444-
permission: Permissions.localAdCreate,
445-
requiresAuthentication: true,
446-
),
447-
putPermission: const ModelActionPermission(
448-
type: RequiredPermissionType.adminOnly,
449-
permission: Permissions.localAdUpdate,
450-
requiresAuthentication: true,
451-
),
452-
deletePermission: const ModelActionPermission(
453-
type: RequiredPermissionType.adminOnly,
454-
permission: Permissions.localAdDelete,
455-
requiresAuthentication: true,
456-
),
457-
),
458428
};
459429

460430
/// Type alias for the ModelRegistry map for easier provider usage.

0 commit comments

Comments
 (0)