Fix redirection after deleting a post
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
4bff6e99a5
commit
722b9de7e3
@ -97,7 +97,7 @@ import { FETCH_POST, CREATE_POST, UPDATE_POST, DELETE_POST } from "../../graphql
|
|||||||
|
|
||||||
import { IPost, PostVisibility } from "../../types/post.model";
|
import { IPost, PostVisibility } from "../../types/post.model";
|
||||||
import Editor from "../../components/Editor.vue";
|
import Editor from "../../components/Editor.vue";
|
||||||
import { IActor, IGroup } from "../../types/actor";
|
import { IActor, IGroup, usernameWithDomain } from "../../types/actor";
|
||||||
import TagInput from "../../components/Event/TagInput.vue";
|
import TagInput from "../../components/Event/TagInput.vue";
|
||||||
import RouteName from "../../router/name";
|
import RouteName from "../../router/name";
|
||||||
import Subtitle from "../../components/Utils/Subtitle.vue";
|
import Subtitle from "../../components/Utils/Subtitle.vue";
|
||||||
@ -233,7 +233,7 @@ export default class EditPost extends Vue {
|
|||||||
if (data && this.post.attributedTo) {
|
if (data && this.post.attributedTo) {
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: RouteName.POSTS,
|
name: RouteName.POSTS,
|
||||||
params: { preferredUsername: this.post.attributedTo.preferredUsername },
|
params: { preferredUsername: usernameWithDomain(this.post.attributedTo) },
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user