Commit 9f08f195 authored by gwenn's avatar gwenn

Oups.

parent 478b66c6
...@@ -19,7 +19,7 @@ func (c *Conn) IntegrityCheck(dbName string, max int, quick bool) error { ...@@ -19,7 +19,7 @@ func (c *Conn) IntegrityCheck(dbName string, max int, quick bool) error {
} else { } else {
prefix = "integrity" prefix = "integrity"
} }
pragmaName = fmt.Sprintf("%s_check(%d)", prefix, max) pragmaName := fmt.Sprintf("%s_check(%d)", prefix, max)
var msg string var msg string
err := c.OneValue(pragma(dbName, pragmaName), &msg) err := c.OneValue(pragma(dbName, pragmaName), &msg)
if err != nil { if err != nil {
...@@ -59,7 +59,7 @@ func (c *Conn) SchemaVersion(dbName string) (int, error) { ...@@ -59,7 +59,7 @@ func (c *Conn) SchemaVersion(dbName string) (int, error) {
// Database name is optional (default is 'main'). // Database name is optional (default is 'main').
// (See http://sqlite.org/pragma.html#pragma_recursive_triggers) // (See http://sqlite.org/pragma.html#pragma_recursive_triggers)
func (c *Conn) SetRecursiveTriggers(dbName string, on bool) error { func (c *Conn) SetRecursiveTriggers(dbName string, on bool) error {
return c.exec(pragma(dbName, fmt.Sprintf("recursive_triggers=%t"), on)) return c.exec(pragma(dbName, fmt.Sprintf("recursive_triggers=%t", on)))
} }
func pragma(dbName, pragmaName string) string { func pragma(dbName, pragmaName string) string {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment