Skip to content

[Stream publication] modification outside Meteor, filter not taken into account #33

@harry-73

Description

@harry-73

Hi,

If the changes are made outside of Meteor, the filter is not taken into account because line 309 always matches.

pub-sub/lib/publish.js

Lines 307 to 311 in 572e7c5

const match = isEmpty(filter) ? {} : { $or: [
convertFilter(filter),
{ 'updateDescription': { '$exists': true } },
{ 'operationType': 'delete' }
]};

By removing this line, it works fine.

Also, i had to add also { fullDocument: 'updateLookup' } option in line 317

const changeStream = rawCollection.watch(pipeline);

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