Add projects to the dashboard and rename some methods
This commit is contained in:
@@ -77,6 +77,16 @@ function is_admin()
|
||||
return $_SESSION['user']['is_admin'] == 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if the user can configure the project (project are previously filtered)
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
function is_project_admin(array $project)
|
||||
{
|
||||
return is_admin() || $project['is_private'] == 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the username
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user