Skip to content

Commit

Permalink
[hotfix] db issues
Browse files Browse the repository at this point in the history
  • Loading branch information
zenlor committed Sep 5, 2023
1 parent 86add5a commit 9eaf6b6
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/moolite/bot/db.clj
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[next.jdbc.result-set :as result-set]
[redelay.core :refer [state]]
[config.core :refer [env]]
[taoensso.timbre :as timbre :refer [info debug]]
[taoensso.timbre :as log :refer [info debug]]
[moolite.bot.db.groups :as groups]
[moolite.bot.db.callouts :as callouts]
[moolite.bot.db.stats :as stats]))
Expand All @@ -23,8 +23,12 @@

(defn execute! [query]
(debug query)
(jdbc/execute! @db query {:return-keys true}))
(try
(jdbc/execute! @db query {:return-keys true})
(catch Exception e (log/error "Error performing execute!" query))))

(defn execute-one! [query]
(debug query)
(jdbc/execute-one! @db query {:return-keys true}))
(try
(jdbc/execute-one! @db query {:return-keys true})
(catch Exception e (log/error "Error performing execute-one!" query))))

0 comments on commit 9eaf6b6

Please sign in to comment.