WhitespaceDataProvider::getCollections() doesn't respect return format
>>> [!note] Migrated issue <!-- Drupal.org comment --> <!-- Migrated from issue #3539969. --> Reported by: [joachim](https://www.drupal.org/user/107701) Related to !29 >>> <h3 id="summary-problem-motivation">Problem/Motivation</h3> <p>The docs in providers.md *imply* that the return value of getCollections() will always have a 'dates' and 'weekly_collection' key.</p> <p>But WhitespaceDataProvider::getCollections() can return just an empty array if there are no collections -- e.g. for a non-residential address.</p> <h4 id="summary-steps-reproduce">Steps to reproduce</h4> <h3 id="summary-proposed-resolution">Proposed resolution</h3> <p>Either fix the docs, or fix WhitespaceDataProvider::getCollections().</p> <p>It would also be better to formally document the return value on the interface rather than in a markdown file.</p> <h3 id="summary-remaining-tasks">Remaining tasks</h3> <h3 id="summary-ui-changes">User interface changes</h3> <h3 id="summary-api-changes">API changes</h3> <h3 id="summary-data-model-changes">Data model changes</h3>
issue