Repository: wagtail/wagtail

Issue:
Issue: Usage of an instead of a.
Usage of an instead of a in

  client/src/includes/tabs.js:   * Set url to have tab an tab hash at the end.

and in many more location


![Screenshot 2024-01-08 203606](https://github.com/wagtail/wagtail/assets/108203322/118165fa-960f-43c6-947c-e8ffa32e7357)

I have already changed the simple an to a in most of them, I hope it helps.

Issue: Usage of an instead of a.
Usage of an instead of a in

  client/src/includes/tabs.js:   * Set url to have tab an tab hash at the end.

and in many more location


![Screenshot 2024-01-08 203606](https://github.com/wagtail/wagtail/assets/108203322/118165fa-960f-43c6-947c-e8ffa32e7357)

I have already changed the simple an to a in most of them, I hope it helps.



Discussion:

Resolving patch:
diff --git a/wagtail/models/i18n.py b/wagtail/models/i18n.py
--- a/wagtail/models/i18n.py
+++ b/wagtail/models/i18n.py
@@ -474,7 +474,7 @@ def set_locale_on_new_instance(sender, instance, **kwargs):
         return
 
     # If this is a fixture load, use the global default Locale
-    # as the page tree is probably in an flux
+    # as the page tree is probably in flux
     if kwargs["raw"]:
         instance.locale = Locale.get_default()
         return


Test patch:
diff --git a/wagtail/admin/tests/pages/test_bulk_actions/test_bulk_publish.py b/wagtail/admin/tests/pages/test_bulk_actions/test_bulk_publish.py
--- a/wagtail/admin/tests/pages/test_bulk_actions/test_bulk_publish.py
+++ b/wagtail/admin/tests/pages/test_bulk_actions/test_bulk_publish.py
@@ -71,12 +71,12 @@ def setUp(self):
 
     def test_publish_view(self):
         """
-        This tests that the publish view responds with an publish confirm page
+        This tests that the publish view responds with a publish confirm page
         """
         # Request confirm publish page
         response = self.client.get(self.url)
 
-        # # Check that the user received an publish confirm page
+        # # Check that the user received a publish confirm page
         self.assertEqual(response.status_code, 200)
         self.assertTemplateUsed(
             response, "wagtailadmin/pages/bulk_actions/confirm_bulk_publish.html"
@@ -206,12 +206,12 @@ def hook_func(request, action_type, pages, action_class_instance):
 
     def test_publish_descendants_view(self):
         """
-        This tests that the publish view responds with an publish confirm page that does not contain the form field 'include_descendants'
+        This tests that the publish view responds with a publish confirm page that does not contain the form field 'include_descendants'
         """
         # Get publish page for page with no descendants
         response = self.client.get(self.url)
 
-        # Check that the user received an publish confirm page
+        # Check that the user received a publish confirm page
         self.assertEqual(response.status_code, 200)
         self.assertTemplateUsed(
             response, "wagtailadmin/pages/bulk_actions/confirm_bulk_publish.html"
@@ -315,12 +315,12 @@ def setUp(self):
 
     def test_publish_descendants_view(self):
         """
-        This tests that the publish view responds with an publish confirm page that contains the form field 'include_descendants'
+        This tests that the publish view responds with a publish confirm page that contains the form field 'include_descendants'
         """
         # Get publish page
         response = self.client.get(self.url)
 
-        # Check that the user received an publish confirm page
+        # Check that the user received a publish confirm page
         self.assertEqual(response.status_code, 200)
         self.assertTemplateUsed(
             response, "wagtailadmin/pages/bulk_actions/confirm_bulk_publish.html"
diff --git a/wagtail/admin/tests/test_collections_views.py b/wagtail/admin/tests/test_collections_views.py
--- a/wagtail/admin/tests/test_collections_views.py
+++ b/wagtail/admin/tests/test_collections_views.py
@@ -535,7 +535,7 @@ def test_page_shows_delete_link_only_if_delete_permitted(self):
         # Retrieve edit form and check fields
         response = self.get(collection_id=self.marketing_sub_collection.id)
         self.assertNotContains(response, "Delete collection")
-        # Add delete permission to parent collection an try again
+        # Add delete permission to parent collection and try again
         GroupCollectionPermission.objects.create(
             group=self.marketing_group,
             collection=self.marketing_collection,
diff --git a/wagtail/contrib/search_promotions/tests.py b/wagtail/contrib/search_promotions/tests.py
--- a/wagtail/contrib/search_promotions/tests.py
+++ b/wagtail/contrib/search_promotions/tests.py
@@ -483,7 +483,7 @@ class TestSearchPromotionsEditView(WagtailTestUtils, TestCase):
     def setUp(self):
         self.user = self.login()
 
-        # Create an search pick to edit
+        # Create a search pick to edit
         self.query = Query.get("Hello")
         self.search_pick = self.query.editors_picks.create(
             page_id=1, sort_order=0, description="Root page"
@@ -645,7 +645,7 @@ class TestSearchPromotionsDeleteView(WagtailTestUtils, TestCase):
     def setUp(self):
         self.login()
 
-        # Create an search pick to delete
+        # Create a search pick to delete
         self.query = Query.get("Hello")
         self.search_pick = self.query.editors_picks.create(
             page_id=1, description="Root page"