service-worker-mock
Advanced tools
Comparing version 1.11.0 to 1.11.1
@@ -14,4 +14,8 @@ const WindowClient = require('./WindowClient'); | ||
matchAll() { | ||
return Promise.resolve(this.clients); | ||
matchAll({ type = 'all' } = {}) { | ||
if (type === 'all') { | ||
return Promise.resolve(this.clients); | ||
} | ||
const matchedClients = this.clients.filter(client => client.type === type); | ||
return Promise.resolve(matchedClients); | ||
} | ||
@@ -18,0 +22,0 @@ |
@@ -5,3 +5,3 @@ const Client = require('./Client'); | ||
class WindowClient extends Client { | ||
constructor(args) { | ||
constructor(...args) { | ||
super(...args); | ||
@@ -8,0 +8,0 @@ |
{ | ||
"name": "service-worker-mock", | ||
"version": "1.11.0", | ||
"version": "1.11.1", | ||
"main": "index.js", | ||
@@ -5,0 +5,0 @@ "repository": { |
24341
644