Skip to content

error if the "creator" is not a user or null #86

Closed
@adryan-ai

Description

@adryan-ai

when performing an $issueService->search
if the creator can not be resolved by the API to a Jira user it returns NULL for the creator

This throws the following error in PHP
PHP Fatal error: Uncaught JsonMapper_Exception: JSON property "creator" in class "JiraRestApi\Issue\IssueField" must not be NULL in C:\t\netresearch\jsonmapper\src\JsonMapper.php:199
Stack trace:
#0 C:\t\vendor\netresearch\jsonmapper\src\JsonMapper.php(280): JsonMapper->map(Object(stdClass), Object(JiraRestApi\Issue\IssueField))
#1 C:\t\vendor\netresearch\jsonmapper\src\JsonMapper.php(382): JsonMapper->map(Object(stdClass), Object(JiraRestApi\Issue\Issue))
#2 C:\t\vendor\netresearch\jsonmapper\src\JsonMapper.php(265): JsonMapper->mapArray(Array, Array, '\JiraRestApi\Is...')
#3 C:\t\vendor\lesstif\php-jira-rest-client\src\Issue\IssueService.php(357): JsonMapper->map(Object(stdClass), Object(JiraRestApi\Issue\IssueSearchResult))
#4 C:\t\wwwroot\servicedeskqueryresult.php(28): JiraRestApi\Issue\IssueService->search('project in (MDS...', 0, 50)
#5 {main}
thrown in C:\t\vendor\netresearch\jsonmapper\src\JsonMapper.php on line 199

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions