File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -40,9 +40,10 @@ class ResourceCollection implements Iterator
4040 */
4141 public function __construct ($ response , $ items , $ pager )
4242 {
43- $ this ->_page = $ response ["meta " ]["page " ];
43+ // Add "meta" fields only when they exist in JSON response
44+ $ this ->_page = isset ($ response ["meta " ]) ? $ response ["meta " ]["page " ] : null ;
4445 $ this ->_items = $ items ;
45- $ this ->_records = $ response ["meta " ][ " records " ];
46+ $ this ->_records = isset ( $ response ["meta " ]) ? $ response [ " meta " ][ " records " ] : null ;
4647 $ this ->_pager = $ pager ;
4748 $ this ->_index = 0 ;
4849 if (isset ($ response ["meta " ]["pages " ])) {
Original file line number Diff line number Diff line change @@ -11,8 +11,8 @@ class Version
1111 * class constants
1212 */
1313 const MAJOR = 2 ;
14- const MINOR = 2 ;
15- const TINY = 0 ;
14+ const MINOR = 1 ;
15+ const TINY = 4 ;
1616
1717 /**
1818 * @ignore
You can’t perform that action at this time.
0 commit comments