Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F85651188
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
6 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/src/boot/routes.js b/src/boot/routes.js
index 4ff5649af3..22d399588b 100644
--- a/src/boot/routes.js
+++ b/src/boot/routes.js
@@ -1,72 +1,76 @@
import PublicTimeline from 'components/public_timeline/public_timeline.vue'
import PublicAndExternalTimeline from 'components/public_and_external_timeline/public_and_external_timeline.vue'
import FriendsTimeline from 'components/friends_timeline/friends_timeline.vue'
import TagTimeline from 'components/tag_timeline/tag_timeline.vue'
import ConversationPage from 'components/conversation-page/conversation-page.vue'
import Interactions from 'components/interactions/interactions.vue'
import DMs from 'components/dm_timeline/dm_timeline.vue'
import UserProfile from 'components/user_profile/user_profile.vue'
import Search from 'components/search/search.vue'
import Settings from 'components/settings/settings.vue'
import Registration from 'components/registration/registration.vue'
import UserSettings from 'components/user_settings/user_settings.vue'
import FollowRequests from 'components/follow_requests/follow_requests.vue'
import OAuthCallback from 'components/oauth_callback/oauth_callback.vue'
import Notifications from 'components/notifications/notifications.vue'
import AuthForm from 'components/auth_form/auth_form.js'
import ChatPanel from 'components/chat_panel/chat_panel.vue'
import WhoToFollow from 'components/who_to_follow/who_to_follow.vue'
import About from 'components/about/about.vue'
-import ExternalUserProfileResolution from 'components/external_user_profile_resolution/external_user_profile_resolution.vue'
+import RemoteUserProfile from 'components/remote_user_profile/remote_user_profile.vue'
export default (store) => {
const validateAuthenticatedRoute = (to, from, next) => {
if (store.state.users.currentUser) {
next()
} else {
next(store.state.instance.redirectRootNoLogin || '/main/all')
}
}
return [
{ name: 'root',
path: '/',
redirect: _to => {
return (store.state.users.currentUser
? store.state.instance.redirectRootLogin
: store.state.instance.redirectRootNoLogin) || '/main/all'
}
},
{ name: 'public-external-timeline', path: '/main/all', component: PublicAndExternalTimeline },
{ name: 'public-timeline', path: '/main/public', component: PublicTimeline },
{ name: 'friends', path: '/main/friends', component: FriendsTimeline, beforeEnter: validateAuthenticatedRoute },
{ name: 'tag-timeline', path: '/tag/:tag', component: TagTimeline },
{ name: 'conversation', path: '/notice/:id', component: ConversationPage, meta: { dontScroll: true } },
- { name: 'external-user-profile-acct',
- path: '/users/acct/:username([^/@]+)@:hostname([^/@]+)',
+ { name: 'remote-user-profile-acct',
+ path: '/remote-users/:username([^/@]+)@:hostname([^/@]+)',
redirect: to => {
return {
- name: 'external-user-profile-resolution',
+ name: 'remote-user-profile',
params: to.params
}
}
},
- { name: 'external-user-profile-resolution', path: '/users/:hostname/:username', component: ExternalUserProfileResolution, beforeEnter: validateAuthenticatedRoute },
+ { name: 'remote-user-profile',
+ path: '/remote-users/:hostname/:username',
+ component: RemoteUserProfile,
+ beforeEnter: validateAuthenticatedRoute
+ },
{ name: 'external-user-profile', path: '/users/:id', component: UserProfile },
{ name: 'interactions', path: '/users/:username/interactions', component: Interactions, beforeEnter: validateAuthenticatedRoute },
{ name: 'dms', path: '/users/:username/dms', component: DMs, beforeEnter: validateAuthenticatedRoute },
{ name: 'settings', path: '/settings', component: Settings },
{ name: 'registration', path: '/registration', component: Registration },
{ name: 'registration-token', path: '/registration/:token', component: Registration },
{ name: 'friend-requests', path: '/friend-requests', component: FollowRequests, beforeEnter: validateAuthenticatedRoute },
{ name: 'user-settings', path: '/user-settings', component: UserSettings, beforeEnter: validateAuthenticatedRoute },
{ name: 'notifications', path: '/:username/notifications', component: Notifications, beforeEnter: validateAuthenticatedRoute },
{ name: 'login', path: '/login', component: AuthForm },
{ name: 'chat', path: '/chat', component: ChatPanel, props: () => ({ floating: false }) },
{ name: 'oauth-callback', path: '/oauth-callback', component: OAuthCallback, props: (route) => ({ code: route.query.code }) },
{ name: 'search', path: '/search', component: Search, props: (route) => ({ query: route.query.query }) },
{ name: 'who-to-follow', path: '/who-to-follow', component: WhoToFollow, beforeEnter: validateAuthenticatedRoute },
{ name: 'about', path: '/about', component: About },
{ name: 'user-profile', path: '/(users/)?:name', component: UserProfile }
]
}
diff --git a/src/components/external_user_profile_resolution/external_user_profile_resolution.js b/src/components/remote_user_profile/remote_user_profile.js
similarity index 87%
rename from src/components/external_user_profile_resolution/external_user_profile_resolution.js
rename to src/components/remote_user_profile/remote_user_profile.js
index 2dfda4f7d2..411f71bcdd 100644
--- a/src/components/external_user_profile_resolution/external_user_profile_resolution.js
+++ b/src/components/remote_user_profile/remote_user_profile.js
@@ -1,23 +1,23 @@
-const ExteralUserProfileResolution = {
+const RemoteUserProfile = {
mounted () {
this.redirect()
},
methods: {
redirect () {
const acct = this.$route.params.username + '@' + this.$route.params.hostname
this.$store.state.api.backendInteractor.externalProfile(acct)
.then((externalUser) => {
if (!externalUser.error) {
this.$store.commit('addNewUsers', [externalUser])
const id = externalUser.id
this.$router.replace({
name: 'external-user-profile',
params: { id: id }
})
}
})
}
}
}
-export default ExteralUserProfileResolution
+export default RemoteUserProfile
diff --git a/src/components/external_user_profile_resolution/external_user_profile_resolution.vue b/src/components/remote_user_profile/remote_user_profile.vue
similarity index 51%
rename from src/components/external_user_profile_resolution/external_user_profile_resolution.vue
rename to src/components/remote_user_profile/remote_user_profile.vue
index 9e8161aff3..8ce51d5424 100644
--- a/src/components/external_user_profile_resolution/external_user_profile_resolution.vue
+++ b/src/components/remote_user_profile/remote_user_profile.vue
@@ -1,9 +1,9 @@
<template>
<div>
</div>
</template>
-<script src="./external_user_profile_resolution.js"></script>
+<script src="./remote_user_profile.js"></script>
<style lang="scss">
</style>
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Sun, Aug 30, 1:11 PM (1 d, 15 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1738002
Default Alt Text
(6 KB)
Attached To
Mode
rPUFE pleroma-fe-upstream
Attached
Detach File
Event Timeline
Log In to Comment