(query structs.LeaderboardPayload)
| 36 | } |
| 37 | |
| 38 | func (q *QueryCache) QueryStatus(query structs.LeaderboardPayload) QueryState { |
| 39 | query.Start, query.Stop = 0, 0 |
| 40 | queryStuff, ok := q.HashStore.Load(query) |
| 41 | if !ok { |
| 42 | return None |
| 43 | } else { |
| 44 | query, ok := queryStuff.(Query) |
| 45 | if !ok { |
| 46 | panic("how the fuck did you fuck this up?") |
| 47 | } |
| 48 | return query.Status |
| 49 | } |
| 50 | } |
| 51 | |
| 52 | // CheckQuery - Checks if the query has been run before, if so, return the query state and data positions if they exist |
| 53 | func (q *QueryCache) CheckQuery(query structs.LeaderboardPayload) (state QueryState, positions []int) { |
no outgoing calls
no test coverage detected