Browse Source

feat: get return CloudObject

未来全栈 3 months ago
parent
commit
521ed7fc27
2 changed files with 5 additions and 2 deletions
  1. 5 1
      src/lib/ncloud.ts
  2. 0 1
      src/main.ts

+ 5 - 1
src/lib/ncloud.ts

@@ -131,7 +131,11 @@ export class CloudQuery {
         });
 
         const json = await response?.json();
-        return json || {};
+        if (json) {
+            let existsObject = this.dataToObj(json)
+            return existsObject;
+        }
+        return null
     }
 
     async find():Promise<Array<CloudObject>> {

+ 0 - 1
src/main.ts

@@ -27,6 +27,5 @@ bootstrapApplication(AppComponent, {
      provideHttpClient(),
      // 添加Diagnostic
      Diagnostic,
-    { provide: RouteReuseStrategy, useClass: IonicRouteStrategy }
   ],
 });