We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d6ca562 commit baeadcfCopy full SHA for baeadcf
README.md
@@ -212,6 +212,17 @@ More examples in directory
212
213
```toStream``` - The property, a function pointer. It is necessary to determine before use. Will be called for send a message to the remote host
214
215
+```undefinedResult``` - allow to set default result of locally called function if it returns undefined
216
+
217
+usage example:
218
+```js
219
+ jrpc.undefinedResult = null; // or false, or whatever
220
+ jrpc.on('find', function(key) {
221
+ if (db.exists(key))
222
+ return db.get(key);
223
+ // If there is nothing found then just return nothing
224
+ });
225
+```
226
## Dependecies
227
228
- NodeJS <= 8.11.4 (if using within a NodeJS app, or compiling) || Latest browser (if using client side)
0 commit comments