Archived
1
0
This commit is contained in:
Jeff Becker 2017-09-11 16:50:57 -04:00
parent 723fa5aff5
commit 22dc099105
No known key found for this signature in database
GPG Key ID: F357B3B42F6F9B05

View File

@ -754,6 +754,9 @@ func (self *PostgresDatabase) UnbanNewsgroup(group string) (err error) {
func (self *PostgresDatabase) NewsgroupBanned(group string) (banned bool, err error) { func (self *PostgresDatabase) NewsgroupBanned(group string) (banned bool, err error) {
var count int64 var count int64
err = self.conn.QueryRow(self.stmt[NewsgroupBanned], group).Scan(&count) err = self.conn.QueryRow(self.stmt[NewsgroupBanned], group).Scan(&count)
if err == sql.ErrNoRows {
err = nil
}
banned = count > 0 banned = count > 0
return return
} }