Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not Able to modify Roles in DotProject #158

shifasiddeqque opened this issue Apr 14, 2021 · 1 comment

Not Able to modify Roles in DotProject #158

shifasiddeqque opened this issue Apr 14, 2021 · 1 comment


Copy link

shifasiddeqque commented Apr 14, 2021

I upgraded dot project to a newer version, I am not able to modify role giving below error
Warning: count(): Parameter must be an array or an object that implements Countable in ./lib/phpgacl/gacl_api.class.php on line 849
All my images are not showing up, giving 403 error
Also getting below error
**Warning: Use of undefined constant LOCALE_FIRST_DAY - assumed 'LOCALE_FIRST_DAY' (this will throw an Error in a future version of PHP) in ./classes/date.class.php on line 10
#dotproject @dotproject-devops #dotprojectError
Please help

Copy link

That definitely requires some changes... did you also upgrade PHP to a newer version? I'd guess so... newer PHP versions are much stricter.

I'm afraid that until these two issues get addressed by the core developers, all you can try is to do a quick & dirty fix:

Open ./lib/phpgacl/gacl_api.class.php on your favourite code editor, search for line 844, and change

if (count($aco_array) == 0) {


if (empty($aco_array) || count($aco_array) == 0) {

Then scroll further down, and on line 849, where you have

if (count($aro_array) == 0 AND count($aro_group_ids) == 0) {

change to:

if ((empty($aro_array) || count($aro_array) == 0) AND (empty($aro_group_ids) || count($aro_group_ids)) == 0) {

That's it for this file... now open ./classes/date.class.php, go to line 10, and where it says


replace the whole line with the following block of code:

if (!empty($AppUI->user_locale)) {
  @include_once(DP_BASE_DIR.'/locales/'.$AppUI->user_locale.'/locales.php');  // LOCALE_FIRST_DAY gets defined here (gwyneth 20210419)
  setlocale(LC_TIME, $AppUI->user_locale);
} else {
  define('DATE_CALC_BEGIN_WEEKDAY', 1);  // reasonable default

This won't fix everything, but at least those two warnings/errors will disappear; as for the images disappearing, have you tried out what I wrote on issue #157? Any luck?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

No branches or pull requests

2 participants