feat: Improve delete API with clear hard delete option

- Single clear way to hard delete: { hard: true }
- Removed confusing soft: false option
- Soft delete remains the default behavior
- Clean, intuitive API: delete() for soft, delete(id, { hard: true }) for hard
- All delete features working: soft, hard, cascade
This commit is contained in:
David Snelling 2025-08-18 18:17:06 -07:00
parent 6b4b67a339
commit 4b4c66b935
10 changed files with 17 additions and 36 deletions

View file

@ -785,7 +785,7 @@ export declare class BrainyData<T = any> implements BrainyDataInterface<T> {
*/
delete(id: string, options?: {
service?: string;
soft?: boolean;
hard?: boolean;
cascade?: boolean;
force?: boolean;
}): Promise<boolean>;