Skip to content

Commit

Permalink
CORE-1120: fixed some problems found during proofreading
Browse files Browse the repository at this point in the history
  • Loading branch information
slr71 committed Sep 18, 2020
1 parent 4c41fad commit 5a9f95e
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions db/listings.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ func v2GetListing(tx *sql.Tx, params *V2NotificationListingParameters) ([]*model
return nil, err
}

// Sort the inner query based on the
// Sort the inner query based on the requested sort order and boundary settings.
innerSortOrder := params.SortOrder
if params.AfterTimestamp != nil {
innerSortOrder = query.SortOrderAscending
Expand Down Expand Up @@ -691,8 +691,6 @@ func GetNotification(tx *sql.Tx, user string, id string) (*model.Notification, e
Column("n.seen").
Column("n.deleted").
Column("n.outgoing_json AS message").
Column("n.id").
Column("n.time_created AS time_created").
From("notifications n").
Join("users u ON n.user_id = u.id").
Join("notification_types nt ON n.notification_type_id = nt.id").
Expand All @@ -718,10 +716,9 @@ func GetNotification(tx *sql.Tx, user string, id string) (*model.Notification, e
var notificationType string
var messageText []byte
var seen, deleted bool
var id, timeCreated string

// Fetch the data for the current row from the database.
err = rows.Scan(&notificationType, &seen, &deleted, &messageText, &id, &timeCreated)
err = rows.Scan(&notificationType, &seen, &deleted, &messageText)
if err != nil {
return nil, errors.Wrap(err, wrapMsg)
}
Expand Down

0 comments on commit 5a9f95e

Please sign in to comment.