diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index d0fac7a..c870612 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -2,7 +2,7 @@ on:
   workflow_dispatch:
   release:
     types:
-      - created
+      - published
 
 name: Release
 
diff --git a/flask_babel/__init__.py b/flask_babel/__init__.py
index a76bf7c..9f94d22 100644
--- a/flask_babel/__init__.py
+++ b/flask_babel/__init__.py
@@ -16,10 +16,10 @@ from typing import List, Callable, Optional, Union
 
 from babel.support import Translations, NullTranslations
 from flask import current_app, g
-from flask.helpers import locked_cached_property
 from babel import dates, numbers, support, Locale
 from pytz import timezone, UTC
 from werkzeug.datastructures import ImmutableDict
+from werkzeug.utils import cached_property
 
 from flask_babel.speaklater import LazyString
 
@@ -221,7 +221,7 @@ class Babel:
         """
         return get_babel().default_domain
 
-    @locked_cached_property
+    @cached_property
     def domain_instance(self):
         """The message domain for the translations.
         """

diff --git a/tests/test_app_factory.py b/tests/test_app_factory.py
new file mode 100644
index 0000000..0dbef3c
--- /dev/null
+++ b/tests/test_app_factory.py
@@ -0,0 +1,24 @@
+import flask
+import flask_babel as babel
+
+
+def test_app_factory():
+    b = babel.Babel()
+
+    def locale_selector():
+        return 'de_DE'
+
+    def create_app():
+        app_ = flask.Flask(__name__)
+        b.init_app(
+            app_,
+            default_locale='en_US',
+            locale_selector=locale_selector
+        )
+        return app_
+
+    app = create_app()
+    with app.test_request_context():
+        assert str(babel.get_locale()) == 'de_DE'
+        assert babel.gettext(u'Hello %(name)s!', name='Peter') == \
+               'Hallo Peter!'

`locked_cached_property` is deprecated as of Flask>=2.3.0
issue: https://github.com/pallets/flask/issues/4993
pr: https://github.com/pallets/flask/pull/4998

This is the only part where this is used. I'm wondering though, whether locking is even needed in this case or if a `werkzeug.utils.cached_property` is enough?

https://github.com/python-babel/flask-babel/blob/69d3340cd0ff52f3e23a47518285a7e6d8f8c640/flask_babel/__init__.py#L224-L228

happy to send a PR swapping the decorator. But just wanted to be sure whether the lock is actually needed.
(tests pass with `werkzeug.utils.cached_property`)

tests/test_app_factory.py::test_app_factory