Skip to content

Commit 52b07f6

Browse files
author
jeacott1
committed
remove the adapter itself from the options passed so config via string works.
1 parent 411daf4 commit 52b07f6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/ParseServer.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,12 @@ class ParseServer {
175175
if (pushOptions.queueOptions) {
176176
delete pushOptions.queueOptions;
177177
}
178+
var tmpAdapter=pushOptions.adapter;
179+
if (pushOptions.adapter && typeof pushOptions.adapter === "string") {
180+
delete pushOptions.adapter;
181+
}
178182
// Pass the push options too as it works with the default
179-
const pushAdapter = loadAdapter(pushOptions && pushOptions.adapter, ParsePushAdapter, pushOptions);
183+
const pushAdapter = loadAdapter(pushOptions && tmpAdapter, ParsePushAdapter, pushOptions);
180184
// We pass the options and the base class for the adatper,
181185
// Note that passing an instance would work too
182186
const pushController = new PushController();

0 commit comments

Comments
 (0)