mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-16 10:16:16 +01:00
Bugfix/link not found (#1296)
Redirect to login page if anonymous tries to access a page without permission Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com> Co-authored-by: Sebastian Sdorra <sebastian.sdorra@cloudogu.com>
This commit is contained in:
committed by
GitHub
parent
bd81d973ec
commit
b4c5f49858
@@ -43,10 +43,9 @@ import EditUser from "./EditUser";
|
||||
import { fetchUserByName, getFetchUserFailure, getUserByName, isFetchUserPending } from "../modules/users";
|
||||
import { EditUserNavLink, SetPasswordNavLink, SetPermissionsNavLink, SetPublicKeysNavLink } from "./../components/navLinks";
|
||||
import { WithTranslation, withTranslation } from "react-i18next";
|
||||
import { getUsersLink } from "../../modules/indexResource";
|
||||
import { mustGetUsersLink } from "../../modules/indexResource";
|
||||
import SetUserPassword from "../components/SetUserPassword";
|
||||
import SetPermissions from "../../permissions/components/SetPermissions";
|
||||
import AddPublicKey from "../components/publicKeys/AddPublicKey";
|
||||
import SetPublicKeys from "../components/publicKeys/SetPublicKeys";
|
||||
|
||||
type Props = RouteComponentProps &
|
||||
@@ -148,7 +147,7 @@ const mapStateToProps = (state: any, ownProps: Props) => {
|
||||
const user = getUserByName(state, name);
|
||||
const loading = isFetchUserPending(state, name);
|
||||
const error = getFetchUserFailure(state, name);
|
||||
const usersLink = getUsersLink(state);
|
||||
const usersLink = mustGetUsersLink(state);
|
||||
return {
|
||||
usersLink,
|
||||
name,
|
||||
|
||||
Reference in New Issue
Block a user