Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CONTRIBUTORS
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ Anand Suresh <[email protected]>
Brett Bergmann <[email protected]>
Burcu Dogan <[email protected]>
Hector Rovira <[email protected]>
Ido Shamun <[email protected]>
Johan Euphrosine <[email protected]>
Marco Ziccardi <[email protected]>
Patrick Costello <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion lib/datastore/entity.js
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@ function keyFromKeyProto(keyProto) {
};

if (keyProto.partitionId && keyProto.partitionId.namespaceId) {
keyOptions.namespaceId = keyProto.partitionId.namespaceId;
keyOptions.namespace = keyProto.partitionId.namespaceId;
}

keyProto.path.forEach(function(path, index) {
Expand Down
4 changes: 2 additions & 2 deletions test/datastore/entity.js
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,7 @@ describe('entity', function() {

it('should set the namespace', function(done) {
entity.Key = function(keyOptions) {
assert.strictEqual(keyOptions.namespaceId, NAMESPACE);
assert.strictEqual(keyOptions.namespace, NAMESPACE);
done();
};

Expand All @@ -581,7 +581,7 @@ describe('entity', function() {
it('should create a proper Key', function(done) {
entity.Key = function(keyOptions) {
assert.deepEqual(keyOptions, {
namespaceId: NAMESPACE,
namespace: NAMESPACE,
path: [
'Kind',
111,
Expand Down