Skip to content

Commit 1fa7150

Browse files
authored
Make is_valid execute an actual query instead of nothing.
Fixes #65
1 parent 2b4370f commit 1fa7150

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ impl r2d2::ManageConnection for SqliteConnectionManager {
161161
}
162162

163163
fn is_valid(&self, conn: &mut Connection) -> Result<(), Error> {
164-
conn.execute_batch("").map_err(Into::into)
164+
conn.execute_batch("SELECT 1;").map_err(Into::into)
165165
}
166166

167167
fn has_broken(&self, _: &mut Connection) -> bool {

0 commit comments

Comments
 (0)