Skip to content

Commit

Permalink
Merge pull request #1569 from Expensify/tyler-sqlite-utils-const-corr…
Browse files Browse the repository at this point in the history
…ectness

Fix constness for SQLiteUtils
  • Loading branch information
bondydaa authored Sep 20, 2023
2 parents f8916a0 + 874a037 commit d55f217
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sqlitecluster/SQLiteUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include <libstuff/SRandom.h>
#include <sqlitecluster/SQLite.h>

int64_t SQLiteUtils::getRandomID(SQLite& db, const string& tableName, const string& column) {
int64_t SQLiteUtils::getRandomID(const SQLite& db, const string& tableName, const string& column) {
int64_t newID = 0;
while (!newID) {
// Select a random number.
Expand Down
2 changes: 1 addition & 1 deletion sqlitecluster/SQLiteUtils.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ class SQLiteUtils {
public:
// Generates a random ID and checks the given tableName and column to ensure
// uniqueness.
static int64_t getRandomID(SQLite& db, const string& tableName, const string& column);
static int64_t getRandomID(const SQLite& db, const string& tableName, const string& column);
};

0 comments on commit d55f217

Please sign in to comment.