From 8f9509f00cceea8dc87403c28b2056db7b246ed4 Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Mon, 22 Apr 2024 16:01:37 -0700 Subject: [PATCH] datasette, not self.ds, in internals documentation --- docs/internals.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/internals.rst b/docs/internals.rst index b57a289a..79585659 100644 --- a/docs/internals.rst +++ b/docs/internals.rst @@ -386,7 +386,7 @@ This is useful when you need to check multiple permissions at once. For example, .. code-block:: python - await self.ds.ensure_permissions( + await datasette.ensure_permissions( request.actor, [ ("view-table", (database, table)), @@ -420,7 +420,7 @@ This example checks if the user can access a specific table, and sets ``private` .. code-block:: python - visible, private = await self.ds.check_visibility( + visible, private = await datasette.check_visibility( request.actor, action="view-table", resource=(database, table), @@ -430,7 +430,7 @@ The following example runs three checks in a row, similar to :ref:`datasette_ens .. code-block:: python - visible, private = await self.ds.check_visibility( + visible, private = await datasette.check_visibility( request.actor, permissions=[ ("view-table", (database, table)),