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

Commit b286567

Browse files
committed
Change transaction promise to resolve snapshot instead of snapshot.val
1 parent 3fa1797 commit b286567

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

angularfire.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@
254254
// transaction has completed before events are raised.
255255
//
256256
// This function returns a promise that will be resolved when the transaction function has completed.
257-
// A successful transaction is resolved with the snapshot.val(). If the transaction is aborted,
257+
// A successful transaction is resolved with the snapshot. If the transaction is aborted,
258258
// the promise will be resolved with null.
259259
object.$transaction = function(updateFn, applyLocally) {
260260
var deferred = self._q.defer();
@@ -264,7 +264,7 @@
264264
} else if(!committed) {
265265
deferred.resolve(null);
266266
} else {
267-
deferred.resolve(snapshot.val());
267+
deferred.resolve(snapshot);
268268
}
269269
}, applyLocally);
270270
};

0 commit comments

Comments
 (0)