Merge pull request #447 from storytold/bflat-fy-profile-link-change

dev-profile to profile link change
This commit is contained in:
BFlat authored and GitHub committed 2024-01-10 11:51:45 +07:00
commit aa88959bf3
2 files changed
+7 -17

No files matched your search

@@ -97,7 +97,6 @@ import { PasswordResetEmailPage } from "./pages/password_reset/PasswordResetEmai
import { PasswordResetVerificationPage } from "./pages/password_reset/PasswordResetVerificationPage";
import DevUpload from "./pages/dev_upload/DevUpload";
import { NewProfilePage } from "./pages/profile/profile_view/NewProfilePage";
import { ProfilePage } from "./pages/profile/profile_view/ProfilePage";
import { ModerationJobControlPage } from "./pages/moderation/job_control/ModerationJobControlPage";
import WeightPage from "./pages/weight/WeightPage";
import ExplorePage from "./pages/explore/ExplorePage";
@@ -300,17 +299,8 @@ class PageContainer extends React.Component<
<ProfileBanFc sessionWrapper={this.props.sessionWrapper} />
</Route>
<Route path="/profile/:username">
<ProfilePage
sessionWrapper={this.props.sessionWrapper}
sessionSubscriptionsWrapper={
this.props.sessionSubscriptionsWrapper
}
/>
</Route>
{/* New Profile Page */}
<Route path="/dev-profile/:username">
<Route path="/profile/:username">
<NewProfilePage
sessionWrapper={this.props.sessionWrapper}
sessionSubscriptionsWrapper={
@@ -86,10 +86,10 @@ function NewProfilePage(this: any, props: Props) {
usePrefixedDocumentTitle(documentTitle);
if (
pathname === `/dev-profile/${username}` ||
pathname === `/dev-profile/${username}/`
pathname === `/profile/${username}` ||
pathname === `/profile/${username}/`
) {
return <Redirect to={`/dev-profile/${username}/media`} />;
return <Redirect to={`/profile/${username}/media`} />;
}
if (notFoundState) {
@@ -355,21 +355,21 @@ function NewProfilePage(this: any, props: Props) {
const tabs = [
{
to: `/dev-profile/${username}/media`,
to: `/profile/${username}/media`,
label: "Media",
content: <MediaTab {...{ username }} />,
icon: faPhotoFilmMusic,
padding: true,
},
{
to: `/dev-profile/${username}/weights`,
to: `/profile/${username}/weights`,
label: "Weights",
content: <WeightsTab {...{ username }} />,
icon: faLayerGroup,
padding: true,
},
{
to: `/dev-profile/${username}/bookmarks`,
to: `/profile/${username}/bookmarks`,
label: "Bookmarks",
content: <BookmarksTab {...{ username }} />,
icon: faBookmark,