This repository was archived by the owner on Apr 7, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
This repository was archived by the owner on Apr 7, 2021. It is now read-only.
Cannot read property 'name' of null #83
Copy link
Copy link
Open
Description
This code:
client.login({ username: 'username', clientUid, password: 'asd' }, (success, data) => {
const query = JSON.stringify({
table: 'table',
query: [
[ 'createdBy', 'eq', 'username' ]
]
})
const result = client.record.getList( 'search?' + query )
result.whenReady(async r => {
const ids = r.getEntries()
let projects = await Promise.all(ids.map(async (id) => this.get(id)))
result.delete()
})
})
throws this error:
21:06:56:691 | received subscription for search?{"table":"table","query":[["createdBy","eq","username"]]}
LOCAL_LISTEN | nothing to stop for R:search?{"table":"table","query":[["createdBy","eq","username"]]}
RECORD_DELETION | search?{"table":"table","query":[["createdBy","eq","username"]]}
21:06:56:708 | discard subscription for search?{"table":"table","query":[["createdBy","eq","username"]]}
21:06:56:709 | Removing search search?{"table":"table","query":[["createdBy","eq","username"]]}
search?{"table":"table","query":[["createdBy","eq","username"]]}
/Users/.../node_modules/bluebird/js/main/async.js:43
fn = function () { throw arg; };
^
TypeError: Cannot read property 'name' of null
at Search._processInitialValues (/Users/.../node_modules/deepstream.io-provider-search-rethinkdb/src/search.js:144:66)
at Search._readChange (/Users/.../node_modules/deepstream.io-provider-search-rethinkdb/src/search.js:103:12)
at /Users/.../node_modules/rethinkdb/cursor.js:261:20
at tryCatcher (/Users/.../node_modules/bluebird/js/main/util.js:26:23)
at Promise.successAdapter (/Users/.../node_modules/bluebird/js/main/nodeify.js:23:30)
at Promise._settlePromiseAt (/Users/.../node_modules/bluebird/js/main/promise.js:582:21)
at Promise._settlePromiseAtPostResolution (/Users/.../node_modules/bluebird/js/main/promise.js:248:10)
at Async._drainQueue (/Users/.../node_modules/bluebird/js/main/async.js:128:12)
at Async._drainQueues (/Users/.../node_modules/bluebird/js/main/async.js:133:10)
at Immediate.Async.drainQueues [as _onImmediate] (/Users/.../node_modules/bluebird/js/main/async.js:15:14)
at runCallback (timers.js:785:20)
at tryOnImmediate (timers.js:747:5)
at processImmediate [as _immediateCallback] (timers.js:718:5)
which completely crashes the deepstream.io server.
Metadata
Metadata
Assignees
Labels
No labels