Skip to content
This repository was archived by the owner on Sep 4, 2020. It is now read-only.
This repository was archived by the owner on Sep 4, 2020. It is now read-only.

Returning List only once using .take(1) results in error #47

@JaneDawson

Description

@JaneDawson

When I return a Firebase List Object only once like this: return this.db.list('/items').take(1); I receive the following error in VS Studio Code:

[ts]
The 'this' context of type 'AfoListObservable<any[]>' is not assignable to method's 'this' of type 'Observable<any[]>'.
Types of property 'lift' are incompatible.
Type '(operator: Operator<any[], R>) => Observable<any[]>' is not assignable to type '(operator: Operator<any[], R>) => Observable'.
Type 'Observable<any[]>' is not assignable to type 'Observable'.
Type 'any[]' is not assignable to type 'R'.

However, everything seems to compile fine.

Returning an object only once (return this.db.object('/items').take(1);) works fine.
When I use AngularFire2 instead, returning a list only once like this works fine.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions