Last active
June 17, 2016 11:19
-
-
Save joy4eg/ab44931de0606b76d78c8edb4ccffcf0 to your computer and use it in GitHub Desktop.
Database issue workaroud
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/lib/Controllers/DatabaseController.js | |
+++ b/lib/Controllers/DatabaseController.js | |
@@ -118,7 +118,6 @@ DatabaseController.prototype.loadSchema = function () { | |
if (!this.schemaPromise) { | |
this.schemaPromise = this.schemaCollection().then(function (collection) { | |
- delete _this.schemaPromise; | |
return SchemaController.load(collection, _this.adapter); | |
}); | |
} | |
--- a/lib/Controllers/SchemaController.js | |
+++ b/lib/Controllers/SchemaController.js | |
@@ -544,7 +544,7 @@ var SchemaController = function () { | |
value: function validateField(className, fieldName, type, freeze) { | |
var _this5 = this; | |
- return this.reloadData().then(function () { | |
+ return Promise.resolve().then(function () { | |
if (fieldName.indexOf(".") > 0) { | |
// subdocument key (x.y) => ok if x is of type 'object' | |
fieldName = fieldName.split(".")[0]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment