Skip to content

Commit 685fc46

Browse files
author
Jen Weber
authored
Merge pull request ember-learn#313 from ember-learn/locks-patch-3-1
Update js-primer.md
2 parents ea8aa85 + 48df4ef commit 685fc46

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

guides/v3.5.0/getting-started/js-primer.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -197,17 +197,17 @@ store.findRecord('person', 1).then(function(person) {
197197

198198
return person.get('post'); //get all the posts linked with person.
199199

200-
}).then(function(posts){
200+
}).then(function(posts) {
201201

202202
myFirstPost = posts.get('firstObject'); //get the first post from collection.
203203
return myFirstPost.get('comment'); //get all the comments linked with myFirstPost.
204204

205-
}).then(function(comments){
205+
}).then(function(comments) {
206206

207207
// do something with comments
208208
return store.findRecord('book', 1); //query for another record
209209

210-
}).catch(function(err){
210+
}).catch(function(err) {
211211

212212
//handle errors
213213

@@ -223,4 +223,4 @@ For further reference you can consult Developer Network articles:
223223
* [`var`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/var)
224224
* [`const`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/const)
225225
* [`let`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/let).
226-
* [`promise`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).
226+
* [`Promise`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).

guides/v3.6.0/getting-started/js-primer.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -197,17 +197,17 @@ store.findRecord('person', 1).then(function(person) {
197197

198198
return person.get('post'); //get all the posts linked with person.
199199

200-
}).then(function(posts){
200+
}).then(function(posts) {
201201

202202
myFirstPost = posts.get('firstObject'); //get the first post from collection.
203203
return myFirstPost.get('comment'); //get all the comments linked with myFirstPost.
204204

205-
}).then(function(comments){
205+
}).then(function(comments) {
206206

207207
// do something with comments
208208
return store.findRecord('book', 1); //query for another record
209209

210-
}).catch(function(err){
210+
}).catch(function(err) {
211211

212212
//handle errors
213213

@@ -223,4 +223,4 @@ For further reference you can consult Developer Network articles:
223223
* [`var`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/var)
224224
* [`const`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/const)
225225
* [`let`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/let).
226-
* [`promise`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).
226+
* [`Promise`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).

0 commit comments

Comments
 (0)