Skip to content

Commit bb78dfb

Browse files
committed
Merge pull request #227 from ParsePlatform/release-1.8.0
Prepare 1.8.0
2 parents ec68f50 + a0d4a6e commit bb78dfb

18 files changed

+1694
-4
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ node_modules
66
test_output
77
*~
88
.DS_Store
9+
.idea/

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "parse",
3-
"version": "1.7.1",
3+
"version": "1.8.0-rc1",
44
"description": "The Parse JavaScript SDK",
55
"homepage": "https://www.parse.com",
66
"keywords": [
@@ -29,6 +29,7 @@
2929
},
3030
"dependencies": {
3131
"babel-runtime": "^5.8.20",
32+
"ws": "^1.0.1",
3233
"xmlhttprequest": "^1.7.0"
3334
},
3435
"devDependencies": {

src/CoreManager.js

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ import type { PushData } from './Push';
2121
type RequestOptions = {
2222
useMasterKey?: boolean;
2323
sessionToken?: string;
24+
installationId?: string;
2425
};
2526
type AnalyticsController = {
2627
track: (name: string, dimensions: { [key: string]: string }) => ParsePromise;
@@ -116,6 +117,7 @@ var config: { [key: string]: mixed } = {
116117
!process.version.electron),
117118
REQUEST_ATTEMPT_LIMIT: 5,
118119
SERVER_URL: 'https://api.parse.com/1',
120+
LIVEQUERY_SERVER_URL: null,
119121
VERSION: 'js' + require('../package.json').version,
120122
APPLICATION_ID: null,
121123
JAVASCRIPT_KEY: null,
@@ -454,5 +456,25 @@ module.exports = {
454456

455457
getUserController(): UserController {
456458
return config['UserController'];
459+
},
460+
461+
setLiveQueryController(controller: any) {
462+
if (typeof controller.subscribe !== 'function') {
463+
throw new Error('LiveQueryController must implement subscribe()');
464+
}
465+
if (typeof controller.unsubscribe !== 'function') {
466+
throw new Error('LiveQueryController must implement unsubscribe()');
467+
}
468+
if (typeof controller.open !== 'function') {
469+
throw new Error('LiveQueryController must implement open()');
470+
}
471+
if (typeof controller.close !== 'function') {
472+
throw new Error('LiveQueryController must implement close()');
473+
}
474+
config['LiveQueryController'] = controller;
475+
},
476+
477+
getLiveQueryController(): any {
478+
return config['LiveQueryController'];
457479
}
458480
}

0 commit comments

Comments
 (0)