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

Catch invalid cache source storage path #26270

Merged
merged 1 commit into from
Mar 24, 2021

Conversation

skjnldsv
Copy link
Member

OC\Files\Cache\Cache::get can also return false

Signed-off-by: John Molakvoæ (skjnldsv) <[email protected]>
@skjnldsv skjnldsv added bug 3. to review Waiting for reviews feature: caching Related to our caching system: scssCacher, jsCombiner... labels Mar 24, 2021
@skjnldsv skjnldsv added this to the Nextcloud 22 milestone Mar 24, 2021
@skjnldsv skjnldsv self-assigned this Mar 24, 2021
@skjnldsv
Copy link
Member Author

/backport to stable21

@skjnldsv
Copy link
Member Author

/backport to stable20

@skjnldsv
Copy link
Member Author

/backport to stable19

@MorrisJobke
Copy link
Member

😭

@MorrisJobke
Copy link
Member

Shouldn't psalm catch this?

Copy link
Member

@MorrisJobke MorrisJobke left a comment

Choose a reason for hiding this comment

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

I still wonder why Psalm didn't found this one as the PHPDoc is correct for them. 🤔

@skjnldsv skjnldsv merged commit 057c72d into master Mar 24, 2021
@skjnldsv skjnldsv deleted the fix/invalid-source-storage-path branch March 24, 2021 11:01
joshtrichards added a commit to joshtrichards/nc-server that referenced this pull request Aug 3, 2023
OC\Files\Cache\Cache::get can return string|false|null, not just string|false.

- nextcloud#26270 added handling of false, but null is needed too.
- Well, or we change the default $resullt to false, but I'm not sure if that has other ramifications and the real need here is to simply catch situations where the cache source storage path is not valid for whatever reason

Related: nextcloud#19009

Signed-off-by: Josh Richards <[email protected]>
backportbot-nextcloud bot pushed a commit that referenced this pull request Aug 5, 2023
OC\Files\Cache\Cache::get can return string|false|null, not just string|false.

- #26270 added handling of false, but null is needed too.
- Well, or we change the default $resullt to false, but I'm not sure if that has other ramifications and the real need here is to simply catch situations where the cache source storage path is not valid for whatever reason

Related: #19009

Signed-off-by: Josh Richards <[email protected]>
backportbot-nextcloud bot pushed a commit that referenced this pull request Aug 5, 2023
OC\Files\Cache\Cache::get can return string|false|null, not just string|false.

- #26270 added handling of false, but null is needed too.
- Well, or we change the default $resullt to false, but I'm not sure if that has other ramifications and the real need here is to simply catch situations where the cache source storage path is not valid for whatever reason

Related: #19009

Signed-off-by: Josh Richards <[email protected]>
backportbot-nextcloud bot pushed a commit that referenced this pull request Aug 6, 2023
OC\Files\Cache\Cache::get can return string|false|null, not just string|false.

- #26270 added handling of false, but null is needed too.
- Well, or we change the default $resullt to false, but I'm not sure if that has other ramifications and the real need here is to simply catch situations where the cache source storage path is not valid for whatever reason

Related: #19009

Signed-off-by: Josh Richards <[email protected]>
kesselb pushed a commit that referenced this pull request Dec 1, 2023
OC\Files\Cache\Cache::get can return string|false|null, not just string|false.

- #26270 added handling of false, but null is needed too.
- Well, or we change the default $resullt to false, but I'm not sure if that has other ramifications and the real need here is to simply catch situations where the cache source storage path is not valid for whatever reason

Related: #19009

Signed-off-by: Josh Richards <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug feature: caching Related to our caching system: scssCacher, jsCombiner...
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants