Skip to content

[liveQuery] Calling js method changed failed #5

@x3kcl

Description

@x3kcl

I get the following error when trying to do a live query:


An uncaught Exception occurred on "main" thread.
com.tns.NativeScriptException: 
Calling js method changed failed

TypeError: Cannot read property 'equals' of null
File: "file:///data/data/org.nativescript.cbp/files/app/tns_modules/nativescript-couchbaselite/index.js, line: 422, column: 23

StackTrace: 
	Frame: function:'changed', file:'file:///data/data/org.nativescript.cbp/files/app/tns_modules/nativescript-couchbaselite/index.js', line: 422, column: 24


	at com.tns.Runtime.callJSMethodNative(Native Method)
	at com.tns.Runtime.access$2400(Runtime.java:34)
	at com.tns.Runtime$3.run(Runtime.java:1095)
	at android.os.Handler.handleCallback(Handler.java:751)
	at android.os.Handler.dispatchMessage(Handler.java:95)
	at android.os.Looper.loop(Looper.java:154)
	at android.app.ActivityThread.main(ActivityThread.java:6119)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)

I use the following code based on your sample:
let listener = { onRows(rows: QueryResult) { console.log("liveQuery"); console.dir(rows); this._dataItems = new ObservableArray( rows ); } }; let live = this.database.liveQuery("movie-live", { mapOnly: true }, listener); live.start();

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions