@ -25,7 +25,7 @@ func getTrustVote(targetID string) ([]int, error) {
return array, nil
}
func updateTrust(sourceID, targetID string, voteValue int) error {
func updateDbTrust(sourceID, targetID string, voteValue int) error {
rows, err := db.Query("SELECT lastUpdated FROM trustVote WHERE sourceUser=? AND targetUser=?", sourceID, targetID)
if err != nil {
return err
@ -35,3 +35,12 @@ func getTotalTrust(s *discordgo.Session) (float64, error) {
return total, nil
err := updateDbTrust(sourceID, targetID, voteValue)
delete(trustCache, targetID)
return nil