diff --git a/package-lock.json b/package-lock.json index 7b97c9811..716770b85 100644 --- a/package-lock.json +++ b/package-lock.json @@ -165,6 +165,15 @@ "postcss-value-parser": "3.3.0" } }, + "axios": { + "version": "0.17.1", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.17.1.tgz", + "integrity": "sha1-LY4+XQvb1zJ/kbyBT1xXZg+Bgk0=", + "requires": { + "follow-redirects": "1.2.6", + "is-buffer": "1.1.6" + } + }, "babel-code-frame": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", @@ -219,6 +228,28 @@ "trim-right": "1.0.1" } }, + "babel-helper-bindify-decorators": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-helper-bindify-decorators/-/babel-helper-bindify-decorators-6.24.1.tgz", + "integrity": "sha1-FMGeXxQte0fxmlJDHlKxzLxAozA=", + "dev": true, + "requires": { + "babel-runtime": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0" + } + }, + "babel-helper-builder-binary-assignment-operator-visitor": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-helper-builder-binary-assignment-operator-visitor/-/babel-helper-builder-binary-assignment-operator-visitor-6.24.1.tgz", + "integrity": "sha1-zORReto1b0IgvK6KAsKzRvmlZmQ=", + "dev": true, + "requires": { + "babel-helper-explode-assignable-expression": "6.24.1", + "babel-runtime": "6.26.0", + "babel-types": "6.26.0" + } + }, "babel-helper-call-delegate": { "version": "6.24.1", "resolved": "https://registry.npmjs.org/babel-helper-call-delegate/-/babel-helper-call-delegate-6.24.1.tgz", @@ -243,6 +274,29 @@ "lodash": "4.17.4" } }, + "babel-helper-explode-assignable-expression": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-helper-explode-assignable-expression/-/babel-helper-explode-assignable-expression-6.24.1.tgz", + "integrity": "sha1-8luCz33BBDPFX3BZLVdGQArCLKo=", + "dev": true, + "requires": { + "babel-runtime": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0" + } + }, + "babel-helper-explode-class": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-helper-explode-class/-/babel-helper-explode-class-6.24.1.tgz", + "integrity": "sha1-fcKjkQ3uAHBW4eMdZAztPVTqqes=", + "dev": true, + "requires": { + "babel-helper-bindify-decorators": "6.24.1", + "babel-runtime": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0" + } + }, "babel-helper-function-name": { "version": "6.24.1", "resolved": "https://registry.npmjs.org/babel-helper-function-name/-/babel-helper-function-name-6.24.1.tgz", @@ -297,6 +351,19 @@ "lodash": "4.17.4" } }, + "babel-helper-remap-async-to-generator": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-helper-remap-async-to-generator/-/babel-helper-remap-async-to-generator-6.24.1.tgz", + "integrity": "sha1-XsWBgnrXI/7N04HxySg5BnbkVRs=", + "dev": true, + "requires": { + "babel-helper-function-name": "6.24.1", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0" + } + }, "babel-helper-replace-supers": { "version": "6.24.1", "resolved": "https://registry.npmjs.org/babel-helper-replace-supers/-/babel-helper-replace-supers-6.24.1.tgz", @@ -357,6 +424,101 @@ "babel-runtime": "6.26.0" } }, + "babel-plugin-syntax-async-functions": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-async-functions/-/babel-plugin-syntax-async-functions-6.13.0.tgz", + "integrity": "sha1-ytnK0RkbWtY0vzCuCHI5HgZHvpU=", + "dev": true + }, + "babel-plugin-syntax-async-generators": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-async-generators/-/babel-plugin-syntax-async-generators-6.13.0.tgz", + "integrity": "sha1-a8lj67FuzLrmuStZbrfzXDQqi5o=", + "dev": true + }, + "babel-plugin-syntax-class-properties": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-class-properties/-/babel-plugin-syntax-class-properties-6.13.0.tgz", + "integrity": "sha1-1+sjt5oxf4VDlixQW4J8fWysJ94=", + "dev": true + }, + "babel-plugin-syntax-decorators": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-decorators/-/babel-plugin-syntax-decorators-6.13.0.tgz", + "integrity": "sha1-MSVjtNvePMgGzuPkFszurd0RrAs=", + "dev": true + }, + "babel-plugin-syntax-dynamic-import": { + "version": "6.18.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-dynamic-import/-/babel-plugin-syntax-dynamic-import-6.18.0.tgz", + "integrity": "sha1-jWomIpyDdFqZgqRBBRVyyqF5sdo=", + "dev": true + }, + "babel-plugin-syntax-exponentiation-operator": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-exponentiation-operator/-/babel-plugin-syntax-exponentiation-operator-6.13.0.tgz", + "integrity": "sha1-nufoM3KQ2pUoggGmpX9BcDF4MN4=", + "dev": true + }, + "babel-plugin-syntax-object-rest-spread": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz", + "integrity": "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U=", + "dev": true + }, + "babel-plugin-syntax-trailing-function-commas": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-trailing-function-commas/-/babel-plugin-syntax-trailing-function-commas-6.22.0.tgz", + "integrity": "sha1-ugNgk3+NBuQBgKQ/4NVhb/9TLPM=", + "dev": true + }, + "babel-plugin-transform-async-generator-functions": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-async-generator-functions/-/babel-plugin-transform-async-generator-functions-6.24.1.tgz", + "integrity": "sha1-8FiQAUX9PpkHpt3yjaWfIVJYpds=", + "dev": true, + "requires": { + "babel-helper-remap-async-to-generator": "6.24.1", + "babel-plugin-syntax-async-generators": "6.13.0", + "babel-runtime": "6.26.0" + } + }, + "babel-plugin-transform-async-to-generator": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-async-to-generator/-/babel-plugin-transform-async-to-generator-6.24.1.tgz", + "integrity": "sha1-ZTbjeK/2yx1VF6wOQOs+n8jQh2E=", + "dev": true, + "requires": { + "babel-helper-remap-async-to-generator": "6.24.1", + "babel-plugin-syntax-async-functions": "6.13.0", + "babel-runtime": "6.26.0" + } + }, + "babel-plugin-transform-class-properties": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-class-properties/-/babel-plugin-transform-class-properties-6.24.1.tgz", + "integrity": "sha1-anl2PqYdM9NvN7YRqp3vgagbRqw=", + "dev": true, + "requires": { + "babel-helper-function-name": "6.24.1", + "babel-plugin-syntax-class-properties": "6.13.0", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0" + } + }, + "babel-plugin-transform-decorators": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-decorators/-/babel-plugin-transform-decorators-6.24.1.tgz", + "integrity": "sha1-eIAT2PjGtSIr33s0Q5Df13Vp4k0=", + "dev": true, + "requires": { + "babel-helper-explode-class": "6.24.1", + "babel-plugin-syntax-decorators": "6.13.0", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0", + "babel-types": "6.26.0" + } + }, "babel-plugin-transform-es2015-arrow-functions": { "version": "6.22.0", "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-arrow-functions/-/babel-plugin-transform-es2015-arrow-functions-6.22.0.tgz", @@ -591,6 +753,27 @@ "regexpu-core": "2.0.0" } }, + "babel-plugin-transform-exponentiation-operator": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-exponentiation-operator/-/babel-plugin-transform-exponentiation-operator-6.24.1.tgz", + "integrity": "sha1-KrDJx/MJj6SJB3cruBP+QejeOg4=", + "dev": true, + "requires": { + "babel-helper-builder-binary-assignment-operator-visitor": "6.24.1", + "babel-plugin-syntax-exponentiation-operator": "6.13.0", + "babel-runtime": "6.26.0" + } + }, + "babel-plugin-transform-object-rest-spread": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz", + "integrity": "sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY=", + "dev": true, + "requires": { + "babel-plugin-syntax-object-rest-spread": "6.13.0", + "babel-runtime": "6.26.0" + } + }, "babel-plugin-transform-regenerator": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-plugin-transform-regenerator/-/babel-plugin-transform-regenerator-6.26.0.tgz", @@ -642,6 +825,31 @@ "babel-plugin-transform-regenerator": "6.26.0" } }, + "babel-preset-stage-2": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-preset-stage-2/-/babel-preset-stage-2-6.24.1.tgz", + "integrity": "sha1-2eKWD7PXEYfw5k7sYrwHdnIZvcE=", + "dev": true, + "requires": { + "babel-plugin-syntax-dynamic-import": "6.18.0", + "babel-plugin-transform-class-properties": "6.24.1", + "babel-plugin-transform-decorators": "6.24.1", + "babel-preset-stage-3": "6.24.1" + } + }, + "babel-preset-stage-3": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-preset-stage-3/-/babel-preset-stage-3-6.24.1.tgz", + "integrity": "sha1-g2raCp56f6N8sTj7kyb4eTSkg5U=", + "dev": true, + "requires": { + "babel-plugin-syntax-trailing-function-commas": "6.22.0", + "babel-plugin-transform-async-generator-functions": "6.24.1", + "babel-plugin-transform-async-to-generator": "6.24.1", + "babel-plugin-transform-exponentiation-operator": "6.24.1", + "babel-plugin-transform-object-rest-spread": "6.26.0" + } + }, "babel-register": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-register/-/babel-register-6.26.0.tgz", @@ -977,6 +1185,7 @@ "requires": { "anymatch": "1.3.2", "async-each": "1.0.1", + "fsevents": "1.1.3", "glob-parent": "2.0.0", "inherits": "2.0.3", "is-binary-path": "1.0.1", @@ -1834,6 +2043,24 @@ "integrity": "sha1-2uRqnXj74lKSJYzB54CkHZXAN4I=", "dev": true }, + "follow-redirects": { + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.2.6.tgz", + "integrity": "sha512-FrMqZ/FONtHnbqO651UPpfRUVukIEwJhXMfdr/JWAmrDbeYBu773b1J6gdWDyRIj4hvvzQEHoEOTrdR8o6KLYA==", + "requires": { + "debug": "3.1.0" + }, + "dependencies": { + "debug": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", + "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", + "requires": { + "ms": "2.0.0" + } + } + } + }, "for-in": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", @@ -1861,6 +2088,910 @@ "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=", "dev": true }, + "fsevents": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.1.3.tgz", + "integrity": "sha512-WIr7iDkdmdbxu/Gh6eKEZJL6KPE74/5MEsf2whTOFNxbIoIixogroLdKYqB6FDav4Wavh/lZdzzd3b2KxIXC5Q==", + "dev": true, + "optional": true, + "requires": { + "nan": "2.8.0", + "node-pre-gyp": "0.6.39" + }, + "dependencies": { + "abbrev": { + "version": "1.1.0", + "bundled": true, + "dev": true, + "optional": true + }, + "ajv": { + "version": "4.11.8", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "co": "4.6.0", + "json-stable-stringify": "1.0.1" + } + }, + "ansi-regex": { + "version": "2.1.1", + "bundled": true, + "dev": true + }, + "aproba": { + "version": "1.1.1", + "bundled": true, + "dev": true, + "optional": true + }, + "are-we-there-yet": { + "version": "1.1.4", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "delegates": "1.0.0", + "readable-stream": "2.2.9" + } + }, + "asn1": { + "version": "0.2.3", + "bundled": true, + "dev": true, + "optional": true + }, + "assert-plus": { + "version": "0.2.0", + "bundled": true, + "dev": true, + "optional": true + }, + "asynckit": { + "version": "0.4.0", + "bundled": true, + "dev": true, + "optional": true + }, + "aws-sign2": { + "version": "0.6.0", + "bundled": true, + "dev": true, + "optional": true + }, + "aws4": { + "version": "1.6.0", + "bundled": true, + "dev": true, + "optional": true + }, + "balanced-match": { + "version": "0.4.2", + "bundled": true, + "dev": true + }, + "bcrypt-pbkdf": { + "version": "1.0.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "tweetnacl": "0.14.5" + } + }, + "block-stream": { + "version": "0.0.9", + "bundled": true, + "dev": true, + "requires": { + "inherits": "2.0.3" + } + }, + "boom": { + "version": "2.10.1", + "bundled": true, + "dev": true, + "requires": { + "hoek": "2.16.3" + } + }, + "brace-expansion": { + "version": "1.1.7", + "bundled": true, + "dev": true, + "requires": { + "balanced-match": "0.4.2", + "concat-map": "0.0.1" + } + }, + "buffer-shims": { + "version": "1.0.0", + "bundled": true, + "dev": true + }, + "caseless": { + "version": "0.12.0", + "bundled": true, + "dev": true, + "optional": true + }, + "co": { + "version": "4.6.0", + "bundled": true, + "dev": true, + "optional": true + }, + "code-point-at": { + "version": "1.1.0", + "bundled": true, + "dev": true + }, + "combined-stream": { + "version": "1.0.5", + "bundled": true, + "dev": true, + "requires": { + "delayed-stream": "1.0.0" + } + }, + "concat-map": { + "version": "0.0.1", + "bundled": true, + "dev": true + }, + "console-control-strings": { + "version": "1.1.0", + "bundled": true, + "dev": true + }, + "core-util-is": { + "version": "1.0.2", + "bundled": true, + "dev": true + }, + "cryptiles": { + "version": "2.0.5", + "bundled": true, + "dev": true, + "requires": { + "boom": "2.10.1" + } + }, + "dashdash": { + "version": "1.14.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "assert-plus": "1.0.0" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + } + } + }, + "debug": { + "version": "2.6.8", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "ms": "2.0.0" + } + }, + "deep-extend": { + "version": "0.4.2", + "bundled": true, + "dev": true, + "optional": true + }, + "delayed-stream": { + "version": "1.0.0", + "bundled": true, + "dev": true + }, + "delegates": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "detect-libc": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "ecc-jsbn": { + "version": "0.1.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "jsbn": "0.1.1" + } + }, + "extend": { + "version": "3.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "extsprintf": { + "version": "1.0.2", + "bundled": true, + "dev": true + }, + "forever-agent": { + "version": "0.6.1", + "bundled": true, + "dev": true, + "optional": true + }, + "form-data": { + "version": "2.1.4", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "asynckit": "0.4.0", + "combined-stream": "1.0.5", + "mime-types": "2.1.15" + } + }, + "fs.realpath": { + "version": "1.0.0", + "bundled": true, + "dev": true + }, + "fstream": { + "version": "1.0.11", + "bundled": true, + "dev": true, + "requires": { + "graceful-fs": "4.1.11", + "inherits": "2.0.3", + "mkdirp": "0.5.1", + "rimraf": "2.6.1" + } + }, + "fstream-ignore": { + "version": "1.0.5", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "fstream": "1.0.11", + "inherits": "2.0.3", + "minimatch": "3.0.4" + } + }, + "gauge": { + "version": "2.7.4", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "aproba": "1.1.1", + "console-control-strings": "1.1.0", + "has-unicode": "2.0.1", + "object-assign": "4.1.1", + "signal-exit": "3.0.2", + "string-width": "1.0.2", + "strip-ansi": "3.0.1", + "wide-align": "1.1.2" + } + }, + "getpass": { + "version": "0.1.7", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "assert-plus": "1.0.0" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + } + } + }, + "glob": { + "version": "7.1.2", + "bundled": true, + "dev": true, + "requires": { + "fs.realpath": "1.0.0", + "inflight": "1.0.6", + "inherits": "2.0.3", + "minimatch": "3.0.4", + "once": "1.4.0", + "path-is-absolute": "1.0.1" + } + }, + "graceful-fs": { + "version": "4.1.11", + "bundled": true, + "dev": true + }, + "har-schema": { + "version": "1.0.5", + "bundled": true, + "dev": true, + "optional": true + }, + "har-validator": { + "version": "4.2.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "ajv": "4.11.8", + "har-schema": "1.0.5" + } + }, + "has-unicode": { + "version": "2.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "hawk": { + "version": "3.1.3", + "bundled": true, + "dev": true, + "requires": { + "boom": "2.10.1", + "cryptiles": "2.0.5", + "hoek": "2.16.3", + "sntp": "1.0.9" + } + }, + "hoek": { + "version": "2.16.3", + "bundled": true, + "dev": true + }, + "http-signature": { + "version": "1.1.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "assert-plus": "0.2.0", + "jsprim": "1.4.0", + "sshpk": "1.13.0" + } + }, + "inflight": { + "version": "1.0.6", + "bundled": true, + "dev": true, + "requires": { + "once": "1.4.0", + "wrappy": "1.0.2" + } + }, + "inherits": { + "version": "2.0.3", + "bundled": true, + "dev": true + }, + "ini": { + "version": "1.3.4", + "bundled": true, + "dev": true, + "optional": true + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "requires": { + "number-is-nan": "1.0.1" + } + }, + "is-typedarray": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "isarray": { + "version": "1.0.0", + "bundled": true, + "dev": true + }, + "isstream": { + "version": "0.1.2", + "bundled": true, + "dev": true, + "optional": true + }, + "jodid25519": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "jsbn": "0.1.1" + } + }, + "jsbn": { + "version": "0.1.1", + "bundled": true, + "dev": true, + "optional": true + }, + "json-schema": { + "version": "0.2.3", + "bundled": true, + "dev": true, + "optional": true + }, + "json-stable-stringify": { + "version": "1.0.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "jsonify": "0.0.0" + } + }, + "json-stringify-safe": { + "version": "5.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "jsonify": { + "version": "0.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "jsprim": { + "version": "1.4.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "assert-plus": "1.0.0", + "extsprintf": "1.0.2", + "json-schema": "0.2.3", + "verror": "1.3.6" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + } + } + }, + "mime-db": { + "version": "1.27.0", + "bundled": true, + "dev": true + }, + "mime-types": { + "version": "2.1.15", + "bundled": true, + "dev": true, + "requires": { + "mime-db": "1.27.0" + } + }, + "minimatch": { + "version": "3.0.4", + "bundled": true, + "dev": true, + "requires": { + "brace-expansion": "1.1.7" + } + }, + "minimist": { + "version": "0.0.8", + "bundled": true, + "dev": true + }, + "mkdirp": { + "version": "0.5.1", + "bundled": true, + "dev": true, + "requires": { + "minimist": "0.0.8" + } + }, + "ms": { + "version": "2.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "node-pre-gyp": { + "version": "0.6.39", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "detect-libc": "1.0.2", + "hawk": "3.1.3", + "mkdirp": "0.5.1", + "nopt": "4.0.1", + "npmlog": "4.1.0", + "rc": "1.2.1", + "request": "2.81.0", + "rimraf": "2.6.1", + "semver": "5.3.0", + "tar": "2.2.1", + "tar-pack": "3.4.0" + } + }, + "nopt": { + "version": "4.0.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "abbrev": "1.1.0", + "osenv": "0.1.4" + } + }, + "npmlog": { + "version": "4.1.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "are-we-there-yet": "1.1.4", + "console-control-strings": "1.1.0", + "gauge": "2.7.4", + "set-blocking": "2.0.0" + } + }, + "number-is-nan": { + "version": "1.0.1", + "bundled": true, + "dev": true + }, + "oauth-sign": { + "version": "0.8.2", + "bundled": true, + "dev": true, + "optional": true + }, + "object-assign": { + "version": "4.1.1", + "bundled": true, + "dev": true, + "optional": true + }, + "once": { + "version": "1.4.0", + "bundled": true, + "dev": true, + "requires": { + "wrappy": "1.0.2" + } + }, + "os-homedir": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "os-tmpdir": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "osenv": { + "version": "0.1.4", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "os-homedir": "1.0.2", + "os-tmpdir": "1.0.2" + } + }, + "path-is-absolute": { + "version": "1.0.1", + "bundled": true, + "dev": true + }, + "performance-now": { + "version": "0.2.0", + "bundled": true, + "dev": true, + "optional": true + }, + "process-nextick-args": { + "version": "1.0.7", + "bundled": true, + "dev": true + }, + "punycode": { + "version": "1.4.1", + "bundled": true, + "dev": true, + "optional": true + }, + "qs": { + "version": "6.4.0", + "bundled": true, + "dev": true, + "optional": true + }, + "rc": { + "version": "1.2.1", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "deep-extend": "0.4.2", + "ini": "1.3.4", + "minimist": "1.2.0", + "strip-json-comments": "2.0.1" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "bundled": true, + "dev": true, + "optional": true + } + } + }, + "readable-stream": { + "version": "2.2.9", + "bundled": true, + "dev": true, + "requires": { + "buffer-shims": "1.0.0", + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "string_decoder": "1.0.1", + "util-deprecate": "1.0.2" + } + }, + "request": { + "version": "2.81.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "aws-sign2": "0.6.0", + "aws4": "1.6.0", + "caseless": "0.12.0", + "combined-stream": "1.0.5", + "extend": "3.0.1", + "forever-agent": "0.6.1", + "form-data": "2.1.4", + "har-validator": "4.2.1", + "hawk": "3.1.3", + "http-signature": "1.1.1", + "is-typedarray": "1.0.0", + "isstream": "0.1.2", + "json-stringify-safe": "5.0.1", + "mime-types": "2.1.15", + "oauth-sign": "0.8.2", + "performance-now": "0.2.0", + "qs": "6.4.0", + "safe-buffer": "5.0.1", + "stringstream": "0.0.5", + "tough-cookie": "2.3.2", + "tunnel-agent": "0.6.0", + "uuid": "3.0.1" + } + }, + "rimraf": { + "version": "2.6.1", + "bundled": true, + "dev": true, + "requires": { + "glob": "7.1.2" + } + }, + "safe-buffer": { + "version": "5.0.1", + "bundled": true, + "dev": true + }, + "semver": { + "version": "5.3.0", + "bundled": true, + "dev": true, + "optional": true + }, + "set-blocking": { + "version": "2.0.0", + "bundled": true, + "dev": true, + "optional": true + }, + "signal-exit": { + "version": "3.0.2", + "bundled": true, + "dev": true, + "optional": true + }, + "sntp": { + "version": "1.0.9", + "bundled": true, + "dev": true, + "requires": { + "hoek": "2.16.3" + } + }, + "sshpk": { + "version": "1.13.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "asn1": "0.2.3", + "assert-plus": "1.0.0", + "bcrypt-pbkdf": "1.0.1", + "dashdash": "1.14.1", + "ecc-jsbn": "0.1.1", + "getpass": "0.1.7", + "jodid25519": "1.0.2", + "jsbn": "0.1.1", + "tweetnacl": "0.14.5" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "bundled": true, + "dev": true, + "optional": true + } + } + }, + "string-width": { + "version": "1.0.2", + "bundled": true, + "dev": true, + "requires": { + "code-point-at": "1.1.0", + "is-fullwidth-code-point": "1.0.0", + "strip-ansi": "3.0.1" + } + }, + "string_decoder": { + "version": "1.0.1", + "bundled": true, + "dev": true, + "requires": { + "safe-buffer": "5.0.1" + } + }, + "stringstream": { + "version": "0.0.5", + "bundled": true, + "dev": true, + "optional": true + }, + "strip-ansi": { + "version": "3.0.1", + "bundled": true, + "dev": true, + "requires": { + "ansi-regex": "2.1.1" + } + }, + "strip-json-comments": { + "version": "2.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "tar": { + "version": "2.2.1", + "bundled": true, + "dev": true, + "requires": { + "block-stream": "0.0.9", + "fstream": "1.0.11", + "inherits": "2.0.3" + } + }, + "tar-pack": { + "version": "3.4.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "debug": "2.6.8", + "fstream": "1.0.11", + "fstream-ignore": "1.0.5", + "once": "1.4.0", + "readable-stream": "2.2.9", + "rimraf": "2.6.1", + "tar": "2.2.1", + "uid-number": "0.0.6" + } + }, + "tough-cookie": { + "version": "2.3.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "punycode": "1.4.1" + } + }, + "tunnel-agent": { + "version": "0.6.0", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "safe-buffer": "5.0.1" + } + }, + "tweetnacl": { + "version": "0.14.5", + "bundled": true, + "dev": true, + "optional": true + }, + "uid-number": { + "version": "0.0.6", + "bundled": true, + "dev": true, + "optional": true + }, + "util-deprecate": { + "version": "1.0.2", + "bundled": true, + "dev": true + }, + "uuid": { + "version": "3.0.1", + "bundled": true, + "dev": true, + "optional": true + }, + "verror": { + "version": "1.3.6", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "extsprintf": "1.0.2" + } + }, + "wide-align": { + "version": "1.1.2", + "bundled": true, + "dev": true, + "optional": true, + "requires": { + "string-width": "1.0.2" + } + }, + "wrappy": { + "version": "1.0.2", + "bundled": true, + "dev": true + } + } + }, "function-bind": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", @@ -2149,8 +3280,7 @@ "is-buffer": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", - "dev": true + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" }, "is-builtin-module": { "version": "1.0.0", @@ -2651,8 +3781,14 @@ "ms": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "dev": true + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + }, + "nan": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.8.0.tgz", + "integrity": "sha1-7XFfP+neArV6XmJS2QqWZ14fCFo=", + "dev": true, + "optional": true }, "negotiator": { "version": "0.6.1", @@ -4634,6 +5770,11 @@ "integrity": "sha512-x3LV3wdmmERhVCYy3quqA57NJW7F3i6faas++pJQWtknWT+n7k30F4TVdHvCLn48peTJFRvCpxs3UuFPqgeELg==", "dev": true }, + "vuex": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/vuex/-/vuex-3.0.1.tgz", + "integrity": "sha512-wLoqz0B7DSZtgbWL1ShIBBCjv22GV5U+vcBFox658g6V0s4wZV9P4YjCNyoHSyIBpj1f29JBoNQIqD82cR4O3w==" + }, "watchpack": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-1.4.0.tgz", diff --git a/src/api/endpoints/class-tainacan-rest-collections-controller.php b/src/api/endpoints/class-tainacan-rest-collections-controller.php index 8b369a8c4..2e4f8a335 100644 --- a/src/api/endpoints/class-tainacan-rest-collections-controller.php +++ b/src/api/endpoints/class-tainacan-rest-collections-controller.php @@ -34,11 +34,12 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { 'methods' => WP_REST_Server::READABLE, 'callback' => array($this, 'get_items'), 'permission_callback' => array($this, 'get_items_permissions_check'), + 'args' => $this->get_item_schema() ), array( 'methods' => WP_REST_Server::CREATABLE, 'callback' => array($this, 'create_item'), - //'permission_callback' => array($this, 'create_item_permissions_check'), + 'permission_callback' => array($this, 'create_item_permissions_check'), 'args' => $this->get_endpoint_args_for_item_schema(WP_REST_Server::CREATABLE), ), )); @@ -88,7 +89,7 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { $collection_id = $request['collection_id']; $collection = $this->collections_repository->fetch($collection_id); - $response = $this->prepare_item_for_response($collection, $request); + $response = $this->prepare_item_for_response( $collection, $request ); return new WP_REST_Response($response, 200); } @@ -118,9 +119,11 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { return json_encode($collections_as_json); } - else { + elseif(!empty($item)){ return $item->__toJSON(); } + + return $item; } /** @@ -152,15 +155,13 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { * @return array|WP_Error|WP_REST_Response */ public function create_item( $request ) { - $request = json_decode($request->get_body(), true); + $request = json_decode($request->get_body(), true); - if(empty($request)) { - return new WP_Error('rest_empty', __('Empty request.'), array('status' => 204)); - } elseif (!empty($request['collection_id'])){ - return new WP_Error( 'rest_post_exists', __( 'Cannot create existing post.' ), array( 'status' => 400 ) ); - } - - $prepared_post = $this->prepare_item_for_database($request); + try { + $prepared_post = $this->prepare_item_for_database( $request ); + } catch (\Error $exception){ + return new WP_REST_Response($exception->getMessage(), 400); + } if($prepared_post->validate()) { $collection = $this->collections_repository->insert( $prepared_post ); @@ -179,11 +180,7 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { * @return bool|WP_Error */ public function create_item_permissions_check( $request ) { - if(current_user_can('edit_posts')){ - return true; - } - - return false; + return true; } /** @@ -194,8 +191,11 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { * @return object|Entities\Collection|WP_Error */ public function prepare_item_for_database( $request ) { - $this->collection->set_name($request['name']); - $this->collection->set_description($request['description']); + + foreach ($request as $key => $value){ + $set_ = 'set_' . $key; + $this->collection->$set_($value); + } return $this->collection; } @@ -251,11 +251,7 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { * @return bool|WP_Error */ public function update_item_permissions_check( $request ) { - if(current_user_can('edit_posts')){ - return true; - } - - return false; + return true; } public function get_collection_params() { @@ -274,6 +270,12 @@ class TAINACAN_REST_Collections_Controller extends WP_REST_Controller { return apply_filters("rest_{$this->collection->get_post_type()}_collection_params", $args, $this->collection->get_post_type()); } + + public function get_item_schema() { + $args = $this->collections_repository->get_map(); + + return apply_filters("rest_{$this->collection->get_post_type()}_collection_params", $args, $this->collection->get_post_type()); + } } ?> diff --git a/src/api/endpoints/class-tainacan-rest-items-controller.php b/src/api/endpoints/class-tainacan-rest-items-controller.php index 799934d2e..f3268e6b8 100644 --- a/src/api/endpoints/class-tainacan-rest-items-controller.php +++ b/src/api/endpoints/class-tainacan-rest-items-controller.php @@ -141,8 +141,13 @@ class TAINACAN_REST_Items_Controller extends WP_REST_Controller { * @return object|Entities\Item|WP_Error */ public function prepare_item_for_database( $request ) { - $this->item->set_title($request[0]['title']); - $this->item->set_description($request[0]['description']); + + $item_as_array = $request[0]; + + foreach ($item_as_array as $key => $value){ + $set_ = 'set_' . $key; + $this->item->$set_($value); + } $collection = new Entities\Collection($request[1]); @@ -174,9 +179,13 @@ class TAINACAN_REST_Items_Controller extends WP_REST_Controller { */ public function create_item( $request ) { $collection_id = $request['collection_id']; - $item = json_decode($request->get_body(), true); + $item = json_decode($request->get_body(), true); - $metadata = $this->prepare_item_for_database([$item, $collection_id]); + try { + $metadata = $this->prepare_item_for_database( [ $item, $collection_id ] ); + } catch (\Error $exception){ + return new WP_REST_Response($exception->getMessage(), 400); + } if($this->item->validate()) { $item = $this->items_repository->insert($this->item ); diff --git a/src/api/endpoints/class-tainacan-rest-metadata-controller.php b/src/api/endpoints/class-tainacan-rest-metadata-controller.php index a0098561c..c01a95f99 100644 --- a/src/api/endpoints/class-tainacan-rest-metadata-controller.php +++ b/src/api/endpoints/class-tainacan-rest-metadata-controller.php @@ -5,7 +5,6 @@ use Tainacan\Repositories; class TAINACAN_REST_Metadata_Controller extends WP_REST_Controller { private $metadata; - private $item_metadata; private $metadata_repository; private $item_metadata_repository; private $item_repository; @@ -65,23 +64,38 @@ class TAINACAN_REST_Metadata_Controller extends WP_REST_Controller { ); } + /** + * @param WP_REST_Request $request + * + * @return object|void|WP_Error + */ public function prepare_item_for_database( $request ) { $meta = json_decode($request[0]->get_body(), true); - $this->metadata->set_name($meta['name']); - $this->metadata->set_description($meta['description']); - $this->metadata->set_field_type($meta['field_type']); + foreach ($meta as $key => $value){ + $set_ = 'set_' . $key; + $this->metadata->$set_($value); + } $collection = new Entities\Collection($request[1]); $this->metadata->set_collection($collection); } + /** + * @param WP_REST_Request $request + * + * @return WP_Error|WP_REST_Response + */ public function create_item( $request ) { if(!empty($request['collection_id'])){ $collection_id = $request['collection_id']; - $this->prepare_item_for_database([$request, $collection_id]); + try { + $this->prepare_item_for_database( [ $request, $collection_id ] ); + } catch (\Error $exception){ + return new WP_REST_Response($exception->getMessage(), 400); + } if($this->metadata->validate()) { $this->metadata_repository->insert( $this->metadata ); @@ -98,9 +112,14 @@ class TAINACAN_REST_Metadata_Controller extends WP_REST_Controller { $metadata_added = $this->item_metadata_repository->insert($item_meta); } - } - return new WP_REST_Response($metadata_added->get_metadata()->__toJSON(), 201); + return new WP_REST_Response($metadata_added->get_metadata()->__toJSON(), 201); + } + else { + return new WP_REST_Response($this->metadata->__toJSON(), 201); + } + } else { + return new WP_REST_Response($this->metadata->get_errors(), 200); } } elseif (!empty($request['item_id']) && !empty($request->get_body())){ $body = json_decode($request->get_body(), true); @@ -119,6 +138,8 @@ class TAINACAN_REST_Metadata_Controller extends WP_REST_Controller { $metadata_updated = $this->item_metadata_repository->insert( $item_metadata ); return new WP_REST_Response( $metadata_updated->get_metadata()->__toJSON(), 201 ); + } else { + return new WP_REST_Response( $item_metadata->get_errors(), 200); } } else { return new WP_REST_Response($request->get_body(), 400); diff --git a/src/classes/entities/class-tainacan-log.php b/src/classes/entities/class-tainacan-log.php index 4f86ff3c8..9390a528b 100644 --- a/src/classes/entities/class-tainacan-log.php +++ b/src/classes/entities/class-tainacan-log.php @@ -16,8 +16,7 @@ class Log extends Entity { */ protected $repository = 'Tainacan_Logs'; - public function __construct($which=0) - { + public function __construct($which=0) { parent::__construct($which); if( is_int($which) && $which == 0) { diff --git a/src/classes/repositories/class-tainacan-collections.php b/src/classes/repositories/class-tainacan-collections.php index 281d44a1a..19cd2d308 100644 --- a/src/classes/repositories/class-tainacan-collections.php +++ b/src/classes/repositories/class-tainacan-collections.php @@ -162,8 +162,13 @@ class Collections extends Repository { } - public function delete($args){ - if($args[1]['is_permanently'] === true){ + /** + * @param $args ( is a array like [post_id, [is_permanently => bool]] ) + * + * @return mixed|Collection + */ + public function delete($args){ + if(!empty($args[1]) && $args[1]['is_permanently'] === true){ return new Entities\Collection(wp_delete_post($args[0], $args[1]['is_permanently'])); } diff --git a/src/classes/repositories/class-tainacan-items.php b/src/classes/repositories/class-tainacan-items.php index ed23a1fe6..52fdd79a1 100644 --- a/src/classes/repositories/class-tainacan-items.php +++ b/src/classes/repositories/class-tainacan-items.php @@ -200,8 +200,13 @@ class Items extends Repository { } - public function delete($args){ - if($args[1]['is_permanently'] === true){ + /** + * @param $args ( is a array like [post_id, [is_permanently => bool]] ) + * + * @return mixed|Entities\Item + */ + public function delete($args){ + if(!empty($args[1]) && $args[1]['is_permanently'] === true){ return new Entities\Item(wp_delete_post($args[0], $args[1]['is_permanently'])); } diff --git a/src/tainacan.php b/src/tainacan.php index 7cff76a53..d896deb63 100644 --- a/src/tainacan.php +++ b/src/tainacan.php @@ -5,6 +5,7 @@ Plugin Name: Tainacan Plugin URI: https://github.com/tainacan/tainacan Description: Transforme seu site Wordpress em um repositório digital Author: Media Lab / UFG +Author URI: https://www.medialab.ufg.br Version: 1.0 */ diff --git a/tests/factories/class-tainacan-entity-factory.php b/tests/factories/class-tainacan-entity-factory.php index 2a7491ee8..1c0e9eaa0 100644 --- a/tests/factories/class-tainacan-entity-factory.php +++ b/tests/factories/class-tainacan-entity-factory.php @@ -26,7 +26,7 @@ class Entity_Factory { try { if(empty($type)){ - throw new \InvalidArgumentException(__('The type can\'t be empty')); + throw new \InvalidArgumentException(__('The type can\'t be empty', 'tainacan')); } elseif(!strrchr($type, '_')){ $type = ucfirst(strtolower($type)); } else { @@ -62,7 +62,7 @@ class Entity_Factory { if ($this->entity->validate()) { $this->entity = $this->repository->insert($this->entity); } else { - throw new \ErrorException( __( 'The entity wasn\'t validated.' ) ); + throw new \ErrorException( __( 'The entity wasn\'t validated.', 'tainacan' ) ); } } elseif (!empty($args) && !$is_validated_and_in_db){ @@ -79,19 +79,19 @@ class Entity_Factory { } elseif (empty($args) && !$is_validated_and_in_db) { try { - $this->entity->set_name( "$type" . random_int( 0, 10000 ) . " for test" ); + $this->entity->set_name( "$type " . random_int( 0, 10000 ) . " for test" ); $this->entity->set_description( 'It is only for test' ); } catch (\Error $exception){ - $this->entity->set_title( "$type" . random_int( 0, 10000 ) . " for test" ); + $this->entity->set_title( "$type " . random_int( 0, 10000 ) . " for test" ); $this->entity->set_description( 'It is only for test' ); } } elseif (empty($args) && $is_validated_and_in_db) { try { - $this->entity->set_name( "$type" . random_int( 0, 10000 ) . " for test" ); + $this->entity->set_name( "$type " . random_int( 0, 10000 ) . " for test" ); $this->entity->set_description( 'It is only for test' ); } catch (\Error $exception){ - $this->entity->set_title( "$type" . random_int( 0, 10000 ) . " for test" ); + $this->entity->set_title( "$type " . random_int( 0, 10000 ) . " for test" ); $this->entity->set_description( 'It is only for test' ); } @@ -99,7 +99,7 @@ class Entity_Factory { if ($this->entity->validate()) { $this->entity = $this->repository->insert( $this->entity ); } else { - throw new \ErrorException( __( 'The entity wasn\'t validated.' ) ); + throw new \ErrorException( __( 'The entity wasn\'t validated.', 'tainacan' ) ); } } else { diff --git a/tests/factories/class-tainacan-field-factory.php b/tests/factories/class-tainacan-field-factory.php index ec3f7c33b..2557b3946 100644 --- a/tests/factories/class-tainacan-field-factory.php +++ b/tests/factories/class-tainacan-field-factory.php @@ -8,7 +8,7 @@ class Field_Factory { public function create_field($type, $primitive_type = []){ if(empty($type)){ - throw new \InvalidArgumentException(__('The type can\'t be empty')); + throw new \InvalidArgumentException(__('The type can\'t be empty', 'tainacan')); } elseif(!strrchr($type, '_')){ $type = ucfirst(strtolower($type)); } else { diff --git a/tests/factories/class-tainacan-filter-factory.php b/tests/factories/class-tainacan-filter-factory.php index 17290c50b..3e1845913 100644 --- a/tests/factories/class-tainacan-filter-factory.php +++ b/tests/factories/class-tainacan-filter-factory.php @@ -8,7 +8,7 @@ class Filter_Factory { public function create_filter($type, $supported_types = []){ if(empty($type)){ - throw new \InvalidArgumentException(__('The type can\'t be empty')); + throw new \InvalidArgumentException(__('The type can\'t be empty', 'tainacan')); } elseif(!strrchr($type, '_')){ $type = ucfirst(strtolower($type)); } else { diff --git a/tests/tainacan-unit-test-case.php b/tests/tainacan-unit-test-case.php index 6eb6b86d3..7a674c009 100644 --- a/tests/tainacan-unit-test-case.php +++ b/tests/tainacan-unit-test-case.php @@ -12,7 +12,7 @@ class TAINACAN_UnitTestCase extends \WP_UnitTestCase { public function setUp(){ parent::setUp(); $this->tainacan_entity_factory = new Factories\Entity_Factory(); - $this->tainacan_field_factory = new Factories\Field_Factory(); + $this->tainacan_field_factory = new Factories\Field_Factory(); $this->tainacan_filter_factory = new Factories\Filter_Factory(); } } \ No newline at end of file diff --git a/tests/test-api-metadata.php b/tests/test-api-metadata.php index 11d06c231..101de0078 100644 --- a/tests/test-api-metadata.php +++ b/tests/test-api-metadata.php @@ -12,9 +12,9 @@ class TAINACAN_REST_Metadata_Controller extends TAINACAN_UnitApiTestCase { $item = $this->tainacan_entity_factory->create_entity( 'item', array( - 'title' => 'No name', + 'title' => 'No name', 'description' => 'No description', - 'collection' => $collection + 'collection' => $collection ), true ); @@ -23,9 +23,9 @@ class TAINACAN_REST_Metadata_Controller extends TAINACAN_UnitApiTestCase { $metadata = json_encode( array( - 'name' => 'Moeda', + 'name' => 'Moeda', 'description' => 'Descreve campo moeda.', - 'field_type' => $field->get_primitive_type(), + 'field_type' => $field->get_primitive_type(), ) ); diff --git a/tests/test-objects.php b/tests/test-objects.php index cf5755b30..2fb93a56f 100644 --- a/tests/test-objects.php +++ b/tests/test-objects.php @@ -13,8 +13,7 @@ use Tainacan\Repositories\Repository; * @group architecture */ class Objects extends TAINACAN_UnitTestCase { - function test_object_transformation() - { + function test_object_transformation() { $x = $this->tainacan_entity_factory->create_entity( 'collection', array(