mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-27 12:43:15 +02:00
parent
f3b518fb62
commit
8bdd4fd061
1 changed files with 6 additions and 4 deletions
|
@ -76,13 +76,15 @@ export default Vue.extend({
|
||||||
this.$root.api('ap/show', {
|
this.$root.api('ap/show', {
|
||||||
uri: acct
|
uri: acct
|
||||||
}).then((res: { type: string, object: any }) => {
|
}).then((res: { type: string, object: any }) => {
|
||||||
if (res.type !== 'User') {
|
if (res.type === 'User') {
|
||||||
|
this.user = res.object;
|
||||||
|
} else if (res.type === 'Note') {
|
||||||
|
this.$router.replace(`/notes/${res.object.id}`);
|
||||||
|
} else {
|
||||||
this.$root.dialog({
|
this.$root.dialog({
|
||||||
type: 'error',
|
type: 'error',
|
||||||
text: 'acct is not an user'
|
text: 'Not supported'
|
||||||
});
|
});
|
||||||
} else {
|
|
||||||
this.user = res.object;
|
|
||||||
}
|
}
|
||||||
}).catch((e: any) => {
|
}).catch((e: any) => {
|
||||||
this.$root.dialog({
|
this.$root.dialog({
|
||||||
|
|
Loading…
Reference in a new issue