Skip to content

Commit 932036d

Browse files
committed
# Conflicts: # lib/modules/storage/index.js # package.json
1 parent ed5c539 commit 932036d

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

lib/modules/presence.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
import invariant from 'invariant';
2-
import { promisify } from '../utils';
32
import { Base, ReferenceBase } from './base';
43

54
class PresenceRef extends ReferenceBase {
65
constructor(presence, ref, pathParts) {
76
super(presence.firestack);
87

8+
this.ref = ref;
99
this.presence = presence;
1010
const db = this.firestack.database();
11-
this.ref = ref;
1211
this.lastOnlineRef = this.ref.child('lastOnline');
1312

1413
this._connectedRef = db.ref('.info/connected');

lib/modules/storage/reference.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,17 @@ import Storage from './';
77

88
const FirestackStorage = NativeModules.FirestackStorage;
99

10-
export default class StorageReference extends ReferenceBase {
10+
export default class StorageRef extends ReferenceBase {
1111
constructor(storage: Storage, path: Array<string>) {
1212
super(storage.firestack, path);
13+
1314
this.storage = storage;
1415
}
1516

1617
downloadUrl(): Promise<Object> {
1718
const path = this.pathToString();
1819
this.log.debug('downloadUrl(', path, ')');
19-
return promisify('downloadUrl', FirestackStorage)(this.storage.storageUrl, path)
20+
return promisify('downloadUrl', FirestackStorage)(path)
2021
.catch((err) => {
2122
this.log.error('Error downloading URL for ', path, '. Error: ', err);
2223
throw err;
@@ -38,7 +39,7 @@ export default class StorageReference extends ReferenceBase {
3839
this.storage._addListener('download_resumed', listener),
3940
];
4041

41-
return promisify('downloadFile', FirestackStorage)(this.storage.storageUrl, path, downloadPath)
42+
return promisify('downloadFile', FirestackStorage)(path, downloadPath)
4243
.then((res) => {
4344
this.log.debug('res --->', res);
4445
listeners.forEach(l => l.remove());

0 commit comments

Comments
 (0)