adobe / adobe/stock-api-libphp
_initial_invalid_state not reset to true on searchFilesInitialize
- Dominant language
- PHP
- Stars
- 20
- Forks
- 23
- PR merge metrics
- No merged PRs in 30d
Description
# Issue report
## Brief description of issue
Code in `searchFilesInitialize` expects `_initial_invalid_state` to be true before making an API call. This flag is set to true in the constructor. After a first call to `searchFilesInitialize` everything works correctly, you can call afterwards `getNextResponse`, `getPreviousResponse`, etc.
However if you try to start a new search with the SearchFiles object calling again `searchFilesInitialize`, you will not be able to use `getNextResponse`, `getPreviousResponse`, etc. because `searchFilesInitialize` doesn't reset `_initial_invalid_state` to true.
## Proposed fix (if applicable)
Add `_initial_invalid_state = true;` add the end of `searchFilesInitialize`.
Contributor guide
Assessment
This issue has not been assessed yet.