Refactor code structure for improved readability and maintainability
This commit is contained in:
@@ -8,7 +8,7 @@ import type {
|
||||
IOrganizationSettings,
|
||||
TOrganizationPlan,
|
||||
} from '../interfaces/auth.interfaces.ts';
|
||||
import { getDb } from './db.ts';
|
||||
import { db } from './db.ts';
|
||||
|
||||
const DEFAULT_SETTINGS: IOrganizationSettings = {
|
||||
requireMfa: false,
|
||||
@@ -17,11 +17,8 @@ const DEFAULT_SETTINGS: IOrganizationSettings = {
|
||||
allowedProtocols: ['oci', 'npm', 'maven', 'cargo', 'composer', 'pypi', 'rubygems'],
|
||||
};
|
||||
|
||||
@plugins.smartdata.Collection(() => getDb())
|
||||
export class Organization
|
||||
extends plugins.smartdata.SmartDataDbDoc<Organization, Organization>
|
||||
implements IOrganization
|
||||
{
|
||||
@plugins.smartdata.Collection(() => db)
|
||||
export class Organization extends plugins.smartdata.SmartDataDbDoc<Organization, Organization> implements IOrganization {
|
||||
@plugins.smartdata.unI()
|
||||
public id: string = '';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user