Commit Graph

1922 Commits

Author SHA1 Message Date
David Cheung ddb5327e64 Update tests for strong-error-handler
Fix rest-adapter related test case switching to strong-error-handler
Only affect the test-cases calling rest methods
2016-06-07 13:26:18 -04:00
Miroslav Bajtoš 276fb5bf69 Merge pull request #2394 from strongloop/remove-express-middleware
[SEMVER-MAJOR] Remove legacy express 3.x middleware getters
2016-06-01 08:33:39 +02:00
Miroslav Bajtoš 8d295b70f6 Remove legacy express 3.x middleware getters
Remove middleware-getter properties that were simlifying upgrade from
LoopBack 1.x/Express 3.x applications:

  - loopback.compress
  - loopback.timeout
  - loopback.cookieParser
  - loopback.cookieSession
  - loopback.csrf
  - loopback.errorHandler
  - loopback.session
  - loopback.methodOverride
  - loopback.logger
  - loopback.responseTime
  - loopback.favicon
  - loopback.directory
  - loopback.vhost

Also remove `loopback.mime`, which was set to `undefined` anyways.
2016-05-31 18:59:21 +02:00
Rand McKinney 70cec0755a Merge pull request #2360 from strongloop/doc/replace
Docuemtation for `replace*` methods
2016-05-20 14:07:25 -07:00
Amir Jafarian eb8f398c6a Docuemtation for `replace*` methods 2016-05-20 16:29:25 -04:00
Amir-61 a9628b9f63 Merge pull request #2349 from strongloop/findORCreate_doc
Make the doc clear for `findORCreate` cb
2016-05-17 18:03:26 -04:00
Amir Jafarian 5c3d021fe7 Make the doc clear for `findORCreate` cb 2016-05-17 17:50:13 -04:00
Miroslav Bajtoš 4fd1d2bcd4 Merge pull request #2327 from strongloop/fix/extra-strong-pm-file
Remove env.json and strong-pm dir
2016-05-13 13:44:09 +02:00
Simon Ho 9ec52ec415 Merge pull request #2336 from jasonwoan/fix/jscs-validatejsdoc-error
Fix JSCS unsupported rule error
2016-05-12 16:52:37 -07:00
Jason 31158f0427 Fix JSCS unsupported rule error
Replace 'validateJSDoc' rule with 'jsDoc'. 'validateJSDoc' was
deprecated in v1.7.0.

In related news, JSCS was recently deprecated in favor of ESlint
so .jscrc can be removed once features have been rolled over.
2016-05-11 23:06:22 -07:00
David Cheung aa47f79ca6 Merge pull request #2301 from strongloop/error-extend-unknown-model
Throw descriptive error upon extending unknown model
2016-05-11 10:39:21 -04:00
Ritchie Martori 09da46a34d Remove env.json and strong-pm dir 2016-05-10 15:23:38 -07:00
David Cheung e723d8b641 Throw error upon extending unknown model
Create Model now uses findModel to retrieve base instead of getModel
and throws error upon base model not found
2016-05-10 18:00:56 -04:00
David Cheung a6f8c07301 Merge pull request #2299 from strongloop/removed-unused-user-properties
[SEMVER-MAJOR] Removed unused user properties
2016-05-10 14:32:32 -04:00
David Cheung 817e76e424 Remove unused UserModel properties
- credentials
- challenges
- status
- created
- lastUpdated
2016-05-10 14:29:08 -04:00
Simon Ho 363bc4d6c1 Merge pull request #2310 from ambrt/ambrt-patch-1
Update user.js
2016-05-09 12:30:17 -07:00
Candy 8a6deb868c Merge pull request #2308 from strongloop/remove_change_handleError
Remove Change.handleError
2016-05-09 12:05:50 -04:00
Candy 8ab6fccdea Remove Change.handleError 2016-05-09 11:45:27 -04:00
Rik 341390a74e Update user.js
allow to change all {href} instances in user.verify() mail into generated url instead of just one
2016-05-08 13:10:56 +02:00
Simon Ho ca1baee0f9 Merge pull request #2297 from supasate/refactor/separate-error-checking-and-next-and-done-logic-from-others
Separate error-checking and next/done logic from other logic
2016-05-06 13:27:29 -07:00
Supasate Choochaisri 04e26fae5c Separate error-checking and next/done logic from other logic in the test suite
Signed-off-by: Supasate Choochaisri <supasate.c@gmail.com>
2016-05-05 11:12:48 +07:00
Simon Ho 1559db2ca3 Merge pull request #2269 from supasate/feature/do-not-allow-duplicate-role-name
Add feature to not allow duplicate role name
2016-05-04 20:42:13 -07:00
Supasate Choochaisri dd78b36a17 Clean up by removing unnecessary comments
Signed-off-by: Supasate Choochaisri <supasate.c@gmail.com>
2016-05-05 08:18:32 +07:00
Supasate Choochaisri d4a869bddf Add feature to not allow duplicate role name
Signed-off-by: Supasate Choochaisri <supasate.c@gmail.com>
2016-05-05 08:18:17 +07:00
Ryan Graham 6964914bab
update copyright statements 2016-05-03 15:50:21 -07:00
Ryan Graham 8acac40ec3
relicense as MIT only 2016-05-03 15:49:10 -07:00
Miroslav Bajtoš 097984154b Merge pull request #2283 from strongloop/add-node-v6-to-travis
travis: drop node@5, add node@6
2016-05-03 18:59:12 +02:00
Miroslav Bajtoš ed766f55b4 Upgrade phantomjs to 2.x 2016-05-03 16:43:45 +02:00
Miroslav Bajtoš 4d7154a31a app: send port:0 instead of port:undefined
Node v6 no longer supports port:undefined, this commit is fixing
app.listen() to correctly send port:0 when no port is specified.
2016-05-03 16:20:07 +02:00
Miroslav Bajtoš 462cec4c1c travis: drop node@5, add node@6 2016-05-03 16:20:07 +02:00
Miroslav Bajtoš 7bc303b4c5 Merge pull request #1989 from strongloop/feature/remove-auto-attach
[SEMVER-MAJOR] Remove "loopback.autoAttach()"
2016-05-03 14:35:51 +02:00
Miroslav Bajtoš 9b39a59813 Disable DEBUG output for eslint on Jenkins CI 2016-05-03 14:01:40 +02:00
Miroslav Bajtoš 87bbf4502a Remove "loopback.autoAttach()"
The method was deprecated since LoopBack 2.0, there is no need to keep
it around in 3.0.
2016-05-03 14:01:39 +02:00
Miroslav Bajtoš 0e6db30640 test/rest.middleware: use local registry
Rework tests in `test/rest.middleware.test.js` to not depend
on `app.autoAttach()` and global shared registry of Models. Instead,
each tests creates a fresh app instance with a new in-memory datasource
and a new set of Models.
2016-05-03 14:01:39 +02:00
Miroslav Bajtoš 35d9fa4b54 Fix role.isOwner to support app-local registry 2016-05-03 14:01:39 +02:00
Miroslav Bajtoš 095dce0373 test/user: use local registry
Rework User tests to not depend on `app.autoAttach()` and global shared
registry of Models. Instead, each tests creates a fresh app instance
with a new in-memory datasource and a new set of Models.
2016-05-03 14:01:39 +02:00
Janny 6b40c69bb3 Merge pull request #2259 from strongloop/feature/resolver-support-return-promise
Resolver support return promise
2016-05-02 21:07:35 -04:00
juehou dcf88baf68 Resolver support return promise 2016-05-02 17:47:14 -04:00
Simon Ho 972a657759 Merge pull request #2273 from bionikspoon/patch-1
remove @private from jsdoc
2016-04-30 18:21:27 -07:00
Manu Phatak 455f0fc0ac remove @private from jsdoc 2016-04-30 18:14:52 -05:00
Simon Ho 69b2b41692 Merge pull request #2272 from strongloop/fix/emit-remote-disabled-event
Fix for `remoteMethodDisabled` PR
2016-04-29 19:36:25 -07:00
Simon Ho d16c789638 Fixes for emit `remoteMethodDisabled` PR
See https://github.com/strongloop/loopback/pull/2266#issuecomment-215689358
2016-04-29 16:42:13 -07:00
Simon Ho 04f5434894 Merge pull request #2266 from supasate/feature/emit-remote-method-disabled-event
Emit a remoteMethodDisabled event when disabling a remote method
2016-04-27 19:53:00 -07:00
Supasate Choochaisri 0ca24389b2 Add new feature to emit a `remoteMethodDisabled` event when disabling a remote method.
Signed-off-by: Supasate Choochaisri <supasate.c@gmail.com>
2016-04-28 09:03:54 +07:00
Miroslav Bajtoš 4cd84dcd8a Merge pull request #2245 from strongloop/fix/nest-remoting-with-hooks
Fix typo in Model.nestRemoting
2016-04-20 09:34:43 +02:00
Tim Needham 159aaf5afa Fix typo in Model.nestRemoting
Prevent apps from crashing when using `Model.nestRemoting` without
`{ hooks: false }` option.

Note that it is not possible to reproduce this bug using our current
Mocha test suite, because other tests modify the global state in such
way that the bug no longer occurs.
2016-04-19 16:51:52 +02:00
Rand McKinney 58f32dd70e Update loopback.js
Update comment line that was creating invalid info in API docs.
2016-04-18 09:42:56 -07:00
Rand McKinney 88d41f84fd Merge pull request #2155 from sghung/master
Fix inconsistencies in JSDoc
2016-04-06 16:01:31 -07:00
Miroslav Bajtoš a9c7801380 Merge pull request #2108 from benkroeger/hotfix/issue-2106
Allow built-in token middleware to run repeatedly
2016-04-06 15:45:21 +02:00
Benjamin Kröger 9e0405de9f Allow built-in token middleware to run repeatedly
Add two new options:

  - When `enableDoublecheck` is true, the middleware will run
    even if a previous middleware has already set `req.accessToken`
    (possibly to `null` for anonymous requests)

  - When `overwriteExistingToken` is true (and `enableDoublecheck` too),
    the middleware will overwrite `req.accessToken` set by a previous
    middleware instances.
2016-04-06 15:44:20 +02:00