Created
August 11, 2014 19:17
-
-
Save BenHall/8b80480dd9d8374b7c38 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var prediction Prediction | |
get_resp := elasticsearch.Get(index, key) | |
if(get_resp == nil) { | |
prediction = Prediction {EventId: eventId, UserId: userid} | |
} else { | |
json.Unmarshal(*get_resp.Source, &prediction) | |
} | |
//cannot convert nil to type elasticsearch.ElasticGetResponse |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment