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

Fixes issue #8 by providing a default 'where' value #10

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

jcdm
Copy link

@jcdm jcdm commented Jul 8, 2017

There's been an issue with PHP7 (or MODX 2.5.7 - not totally sure which) where the user must add a &where=[] to the getArchives call to avoid a server 500 error.

This update provides that default in the snippet if no setting has been passed from the snippet call.

There's been an issue with PHP7 (or MODX 2.5.7 - not totally sure which) where the user must add a &where=`[]` to the getArchives call to avoid a server 500 error.

This update provides that default if no setting has been passed from the snippet call.
@jpdevries
Copy link

Anyone know if there is a maintainer for Archivist? Any volunteers? 😃

@arjen-t
Copy link

arjen-t commented Jul 19, 2019

What is the procedure within the MODX community to become the official maintainer of an existing package? I would be interested to take this one.

@rthrash
Copy link
Member

rthrash commented Aug 28, 2019

This pull request has been mentioned on Community. There might be relevant details there:

https://community.modx.com/t/archivist-landing-page-blank/1420/1

@matdave matdave requested a review from garryn March 19, 2020 19:17
@gadgetto
Copy link

Is this repo still maintained? This pull request needs to be merged.

@@ -49,7 +49,7 @@
}

/* get filter by year, month, and/or day. Sanitize to prevent injection. */
$where = $modx->getOption('where',$scriptProperties,false);
$where = $modx->getOption('where',$scriptProperties,"[]");
$where = is_array($where) ? $where : $modx->fromJSON($where);
$parameters = $modx->request->getParameters();
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If where contains an invalid JSON, the following line has to be added.

$where = !empty($where) ? $where : array();

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

Successfully merging this pull request may close these issues.

7 participants