Skip to content

Commit 424f144

Browse files
author
Ajay Kannan
committed
fix snippets to match full code
1 parent a07fbda commit 424f144

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gcloud-java-datastore/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ Then add the following code to put an entity in Datastore.
9191
KeyFactory keyFactory = datastore.newKeyFactory().kind("Person");
9292
Key key = keyFactory.newKey("John Doe");
9393
Entity entity = Entity.builder(key)
94-
.set("age", 30)
94+
.set("age", 51)
9595
.set("favorite_food", "pizza")
9696
.build();
9797
datastore.put(entity);
@@ -100,7 +100,7 @@ datastore.put(entity);
100100
Later, if you want to get this entity back, add the following to your code:
101101

102102
```java
103-
Entity johnEntity = datastore.get("John Doe");
103+
Entity johnEntity = datastore.get(key);
104104
```
105105

106106
#### Running a query

0 commit comments

Comments
 (0)