Fix nav issue
This commit is contained in:
parent
70fd59a4be
commit
01589eedeb
3 changed files with 5 additions and 6 deletions
|
|
@ -81,12 +81,11 @@ def index():
|
|||
print('Redirect to dashboard')
|
||||
return redirect('/dashboard/')
|
||||
|
||||
@app.route('/profile/', defaults={'path': ''})
|
||||
@app.route('/dashboard/', defaults={'path': ''})
|
||||
@app.route('/dashboard/')
|
||||
@app.route('/profile/')
|
||||
@app.route('/orders/<path:path>')
|
||||
@app.route('/dashboard/<path:path>')
|
||||
@login_required
|
||||
def dashboard(path):
|
||||
def dashboard(path=''):
|
||||
return render_template('dashboard.html')
|
||||
|
||||
@app.route('/logout')
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ export const Header: React.FC = () => {
|
|||
const navigate = useNavigate();
|
||||
|
||||
const handleClick = React.useCallback(() => {
|
||||
navigate("/profile");
|
||||
navigate("/profile/");
|
||||
}, []);
|
||||
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -134,7 +134,7 @@ export const Profile: React.FC = () => {
|
|||
<Title>{username}</Title>
|
||||
</Flex>
|
||||
<Box mb="md">
|
||||
<Link to={`/dashboard`}>Return to dashboard</Link>
|
||||
<Link to={`/dashboard/`}>Return to dashboard</Link>
|
||||
</Box>
|
||||
<Paper bg="gray.1">
|
||||
<Title order={4}>Mastodon</Title>
|
||||
|
|
|
|||
Loading…
Reference in a new issue