Skip to content

Commit

Permalink
Merge pull request #53 from mzedel/me-340
Browse files Browse the repository at this point in the history
ME-340 - fix: fixed an issue that prevented showing PATs on page refresh
  • Loading branch information
mzedel authored Oct 7, 2024
2 parents 29e1457 + bde80fe commit bc7b2cd
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions frontend/src/js/components/settings/accesstokenmanagement.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,15 +195,18 @@ export const AccessTokenManagement = () => {
const [showRevocation, setShowRevocation] = useState(false);
const [currentToken, setCurrentToken] = useState(null);
const isEnterprise = useSelector(getIsEnterprise);
const { tokens = [], roles: userRoles = [] } = useSelector(getCurrentUser);
const { tokens = [], roles: userRoles = [], id } = useSelector(getCurrentUser);
const rolesById = useSelector(state => state.users.rolesById);
const dispatch = useDispatch();

const { classes } = useStyles();

useEffect(() => {
if (!id) {
return;
}
dispatch(getTokens());
}, [dispatch]);
}, [dispatch, id]);

const toggleGenerateClick = () => {
setCurrentToken(null);
Expand Down

0 comments on commit bc7b2cd

Please sign in to comment.