Skip to content

Commit afbea60

Browse files
author
Burcu Dogan
committed
Merge pull request #22 from silvolu/master
Fixes for queries examples in README.
2 parents 8614669 + 08d2055 commit afbea60

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -184,10 +184,10 @@ You can sort the results by a property name ascendingly or descendingly.
184184

185185
~~~~ js
186186
// sorts by size ascendingly.
187-
var q = ds.createQuery('Company').sort('+size');
187+
var q = ds.createQuery('Company').order('+size');
188188

189189
// sorts by size descendingly.
190-
var q = ds.createQuery('Company').sort('-size');
190+
var q = ds.createQuery('Company').order('-size');
191191
~~~~
192192

193193
##### Selection (or Projection)
@@ -205,7 +205,7 @@ Pagination allows you to set an offset, limit and starting cursor to a query.
205205

206206
~~~~ js
207207
var q = ds.createQuery('Company')
208-
.offset(100) // start from 100th result
208+
.offset(100) // start from 101th result
209209
.limit(10) // return only 10 results
210210
.start(cursorToken); // continue to retrieve results from the given cursor.
211211
~~~~

lib/datastore/entity.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ var keyToKeyProto = function(datasetId, key) {
8080
}
8181
var namespace = null, start = 0;
8282
if (key.length % 2 == 1) {
83-
// the first item is the namepsace
83+
// the first item is the namespace
8484
namespace = key[0];
8585
start = 1;
8686
}

0 commit comments

Comments
 (0)