mirror of
https://github.com/flarum/core.git
synced 2025-08-07 08:56:38 +02:00
Fix going from one user page directly to another
This commit is contained in:
committed by
Franz Liedke
parent
c8f47d519d
commit
f67194484b
@@ -27,6 +27,17 @@ export default class UserPage extends Page {
|
||||
this.user = null;
|
||||
|
||||
this.bodyClass = 'App--user';
|
||||
|
||||
this.prevUsername = m.route.param('username');
|
||||
}
|
||||
|
||||
onbeforeupdate() {
|
||||
const currUsername = m.route.param('username');
|
||||
if (currUsername !== this.prevUsername) {
|
||||
this.prevUsername = currUsername;
|
||||
|
||||
this.loadUser(currUsername);
|
||||
}
|
||||
}
|
||||
|
||||
view() {
|
||||
|
Reference in New Issue
Block a user