badmfck-api-server 4.0.87 → 4.0.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -127,7 +127,7 @@ export declare class DBService extends BaseService {
|
|
|
127
127
|
adapter: IDBAdapter | null;
|
|
128
128
|
constructor(options: IDBSericeOptions);
|
|
129
129
|
init(): Promise<void>;
|
|
130
|
-
escape(id: string, value: string): string;
|
|
130
|
+
static escape(id: string, value: string): string;
|
|
131
131
|
getAdapter(dbid?: string | null): IDBAdapter | IDBError;
|
|
132
132
|
reportQuery(result: IDBResult, req: IDBQuery): Promise<void>;
|
|
133
133
|
finishService(): Promise<void>;
|
|
@@ -240,8 +240,8 @@ class DBService extends BaseService_1.BaseService {
|
|
|
240
240
|
return errorResult;
|
|
241
241
|
};
|
|
242
242
|
}
|
|
243
|
-
escape(id, value) {
|
|
244
|
-
const adapter =
|
|
243
|
+
static escape(id, value) {
|
|
244
|
+
const adapter = DBService.allInstances.find(i => i.options.id === id)?.adapter;
|
|
245
245
|
if (!adapter || "errno" in adapter)
|
|
246
246
|
return value;
|
|
247
247
|
return adapter.escape(value);
|