Skip to content

[stable30] feat: add command to get basic storage info - #52865

Closed
backportbot[bot] wants to merge 2 commits into
stable30from
backport/51818/stable30
Closed

[stable30] feat: add command to get basic storage info#52865
backportbot[bot] wants to merge 2 commits into
stable30from
backport/51818/stable30

Conversation

@backportbot

@backportbotbackportbotBot commented May 15, 2025

Copy link
Copy Markdown

Backport of #51818

Warning, This backport's changes differ from the original and might be incomplete ⚠️

Todo

  • Review and resolve any conflicts
  • Amend HEAD commit to remove the line stating to skip CI

Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.

@backportbotbackportbotBot added the 3. to review Waiting for reviews label May 15, 2025
@backportbotbackportbotBot added this to the Nextcloud 30.0.11 milestone May 15, 2025
@icewind1991
icewind1991force-pushed the backport/51818/stable30 branch from ddcac04 to 269b56cCompareMay 15, 2025 11:52
@icewind1991
icewind1991force-pushed the backport/51818/stable30 branch from 269b56c to 0ea3a58CompareMay 16, 2025 19:38
->from('storages')
->where($query->expr()->eq('id', $query->createNamedParameter($id)));
$result = $query->executeQuery()->fetchOne();
return $result ? (int)$result : null;

Check notice

Code scanning / Psalm

RiskyTruthyFalsyComparison

Operand of type false|mixed contains type mixed, which can be falsy and truthy. This can cause possibly unexpected behavior. Use strict comparison instead.
public function execute(InputInterface $input, OutputInterface $output): int {
$storage = $input->getArgument('storage');
$storageId = $this->fileUtils->getNumericStorageId($storage);
if (!$storageId) {

Check notice

Code scanning / Psalm

RiskyTruthyFalsyComparison

Operand of type int|null contains type int, which can be falsy and truthy. This can cause possibly unexpected behavior. Use strict comparison instead.
Signed-off-by: Robin Appelman <robin@icewind.nl>
Signed-off-by: Robin Appelman <robin@icewind.nl>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to reviewWaiting for reviews

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants

@artonge@github-advanced-security@icewind1991@AndyScherzinger@blizzz@Altahrim@skjnldsv