feathersjs-ecosystem / feathers-sync

Synchronize service events between Feathers application instances
MIT License
221 stars 41 forks source link

Error when passing redisClient and not uri #197

Open palmtown opened 4 months ago

palmtown commented 4 months ago

Steps to reproduce

If passing a redisClient object as shown in Exhibit 1, current code will throw an error as it is expecting the uri. However, when passing the redisClient the uri is not required.

Exhibit 1 app.configure( sync({ redisClient }) );

You can reproduce by configuring feathersjs sync as shown in the Exhibit 1 snipplet above.

Expected behavior

Code should not generate an error when a redisClient object is passed.

Actual behavior

Code throws the error: A uri option with the database connection string, or a redisClient object has to be provided to feathers-sync

I have resolved the issue and created a pull request at: https://github.com/feathersjs-ecosystem/feathers-sync/pull/196