dj32: replace url by re_path (#72942)

This commit is contained in:
Benjamin Dauvergne 2023-01-10 18:48:52 +01:00
parent 321be9396c
commit 3f70e53875
1 changed files with 4 additions and 4 deletions

View File

@ -14,19 +14,19 @@
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from django.conf.urls import url
from django.contrib import admin
from django.urls import re_path
from .api_views import PetalAPIKeysView, PetalAPIView
urlpatterns = [
url(r'^admin/', admin.site.urls),
url(
re_path(r'^admin/', admin.site.urls),
re_path(
r'^api/(?P<partner_name>[\w,-]+)/(?P<cut_uuid>[\w,-]{,255})/$',
PetalAPIKeysView.as_view(),
name='api-keys',
),
url(
re_path(
r'^api/(?P<partner_name>[\w,-]+)/(?P<cut_uuid>[\w,-]{,255})/(?P<petal_name>[\w,-]+)/$',
PetalAPIView.as_view(),
name='api',