Skip to content

Commit

Permalink
fix redirects
Browse files Browse the repository at this point in the history
  • Loading branch information
matfish3 committed Nov 20, 2021
1 parent 089560c commit 4523e41
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/templates/blogify/filters/author/_entry.twig
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% extends 'blogify/_layout' %}
{% set author = craft.users().username(craft.app.request.getQueryParam('author')).one() %}
{% if (not author) %}
{% redirect '/blog' %}
{% redirect '/blog/index' %}
{% endif %}

{% block content %}
Expand Down
2 changes: 1 addition & 1 deletion src/templates/blogify/filters/tag/_entry.twig
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% extends 'blogify/_layout' %}
{% set tag = craft.tags().id(craft.app.request.getQueryParam('tag')).one() %}
{% if (not tag) %}
{% redirect '/blog' %}
{% redirect '/blog/index' %}
{% endif %}

{% block content %}
Expand Down

0 comments on commit 4523e41

Please sign in to comment.