Skip to content

Commit

Permalink
Remove some SQL debug logs to unclutter the output.
Browse files Browse the repository at this point in the history
Signed-off-by: alex-z <blackslayer4@gmail.com>
  • Loading branch information
allexzander committed Apr 28, 2023
1 parent 6eb248b commit 6932ba0
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
4 changes: 0 additions & 4 deletions src/common/ownsql.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -292,8 +292,6 @@ bool SqlQuery::isPragma()

bool SqlQuery::exec()
{
qCDebug(lcSql) << "SQL exec" << _sql;

if (!_stmt) {
qCWarning(lcSql) << "Can't exec query, statement unprepared.";
return false;
Expand Down Expand Up @@ -324,8 +322,6 @@ bool SqlQuery::exec()
qCWarning(lcSql) << "IOERR system errno: " << sqlite3_system_errno(_db);
#endif
}
} else {
qCDebug(lcSql) << "Last exec affected" << numRowsAffected() << "rows.";
}
return (_errId == SQLITE_DONE); // either SQLITE_ROW or SQLITE_DONE
}
Expand Down
3 changes: 0 additions & 3 deletions src/common/ownsql.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,20 +135,17 @@ class OCSYNC_EXPORT SqlQuery
template<class T, typename std::enable_if<std::is_enum<T>::value, int>::type = 0>
void bindValue(int pos, const T &value)
{
qCDebug(lcSql) << "SQL bind" << pos << value;
bindValueInternal(pos, static_cast<int>(value));
}

template<class T, typename std::enable_if<!std::is_enum<T>::value, int>::type = 0>
void bindValue(int pos, const T &value)
{
qCDebug(lcSql) << "SQL bind" << pos << value;
bindValueInternal(pos, value);
}

void bindValue(int pos, const QByteArray &value)
{
qCDebug(lcSql) << "SQL bind" << pos << QString::fromUtf8(value);
bindValueInternal(pos, value);
}

Expand Down

0 comments on commit 6932ba0

Please sign in to comment.