Skip to content

Commit

Permalink
fix QsqueryQueryData Data type for query results api call
Browse files Browse the repository at this point in the history
  • Loading branch information
Bogdan Peter committed Aug 8, 2024
1 parent 1b67aa4 commit 6e4cd89
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions api/postgres.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package main

import (
"encoding/json"

"gorm.io/gorm"
)

Expand All @@ -12,12 +10,12 @@ type OsqueryQueryData struct {
UUID string `gorm:"index"`
Environment string
Name string
Data json.RawMessage
Data string
Status int
}

// APIQueryData to return query results from API
type APIQueryData map[string]json.RawMessage
type APIQueryData map[string]string

// Function to retrieve the query log by name
func postgresQueryLogs(name string) (APIQueryData, error) {
Expand Down

0 comments on commit 6e4cd89

Please sign in to comment.