Skip to content

📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

small-fix

kruzhambus5eedf52c884f
diff --git a/src/pages/Project/View/ViewProject.jsx b/src/pages/Project/View/ViewProject.jsx
index 481b3766a..6e5c6a66b 100644
--- a/src/pages/Project/View/ViewProject.jsx
+++ b/src/pages/Project/View/ViewProject.jsx
@@ -81,7 +81,7 @@ const ViewProject = ({
const dashboardRef = useRef(null)
const { id } = useParams()
const history = useHistory()
- const project = useMemo(() => _find([...projects, ..._map(sharedProjects, (item) => item.project)], p => p.id === id) || {}, [projects, id, sharedProjects])
+ const project = useMemo(() => _find([...projects, ..._map(sharedProjects, (item) => ({ ...item.project, role: item.role }))], p => p.id === id) || {}, [projects, id, sharedProjects])
const isSharedProject = useMemo(() => {
const foundProject = _find([..._map(sharedProjects, (item) => item.project)], p => p.id === id)
return !_isEmpty(foundProject)
@@ -1488,7 +1488,7 @@ const ViewProject = ({
})}
>
<div className={cx('xs:mt-0', {
- 'mt-14': !((project.isPublic && !project.isOwner) || (isSharedProject && project.role !== roleAdmin)),
+ 'mt-14': project.public || (isSharedProject && project.role === roleAdmin.role) || project.isOwner,
})}
/>
<div className='relative'>