Tweaks to prepare_connection() example in docs, refs #574

This commit is contained in:
Simon Willison 2023-07-22 16:13:46 -07:00
commit e337a88b45

View file

@ -126,13 +126,12 @@ aggregates and collations. For example:
.. code-block:: python
import click
import sqlite_utils
@sqlite_utils.hookimpl
def prepare_connection(conn):
conn.create_function(
"hello", 1, lambda name: f"Hello, {name}!"
"hello", 1, lambda name: f"Hello, {name}!"
)
This registers a SQL function called ``hello`` which takes a single