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

Commit 4eb223e

Browse files
committed
Use .includes instead of .indexOf
1 parent 522221c commit 4eb223e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/api/pubsub.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const http = require('http')
1010
let activeSubscriptions = []
1111

1212
const subscriptionExists = (subscriptions, topic) => {
13-
return subscriptions.indexOf(topic) !== -1
13+
return subscriptions.includes(topic)
1414
}
1515
const removeSubscription = (subscriptions, topic) => {
1616
const indexToRemove = subscriptions.indexOf(topic)

0 commit comments

Comments
 (0)