Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement getLog for SQLite #3279

Merged
merged 24 commits into from
Sep 4, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
wip
  • Loading branch information
rumyantseva committed Aug 31, 2023
commit 76b8d996fbc616fd6c969e2c5e2a5a0868651bf1
7 changes: 6 additions & 1 deletion internal/backends/sqlite/metadata/registry.go
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,12 @@ func (r *Registry) Version(ctx context.Context) (string, error) {
return r.version, nil
}

row := r.p.GetFirst(ctx).QueryRowContext(context.Background(), "SELECT sqlite_version()")
db := r.p.GetFirst(ctx)
if db == nil {
return "", nil
}

row := db.QueryRowContext(context.Background(), "SELECT sqlite_version()")
chilagrow marked this conversation as resolved.
Show resolved Hide resolved
if err := row.Scan(&r.version); err != nil {
chilagrow marked this conversation as resolved.
Show resolved Hide resolved
return "", lazyerrors.Error(err)
}
Expand Down