Set module path for Page to appease Sphinx autodoc

pull/12894/head
Matt Westcott 2025-02-22 01:08:59 +00:00
rodzic 8559ae9d68
commit a6f2a68aae
1 zmienionych plików z 5 dodań i 0 usunięć

Wyświetl plik

@ -2013,6 +2013,11 @@ class Page(AbstractPage, index.Indexed, ClusterableModel, metaclass=PageBase):
]
# set module path of Page so that when Sphinx autodoc sees Page in type annotations
# it won't complain that there's no target for wagtail.models.pages.Page
Page.__module__ = "wagtail.models"
class GroupPagePermissionManager(models.Manager):
def create(self, **kwargs):
# Simplify creation of GroupPagePermission objects by allowing one