ソースを参照

Small fix in OC_API

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
tags/v26.0.0beta1
Côme Chilliet 1年前
コミット
e4a780127d
コミッターのメールアドレスに関連付けられたアカウントが存在しません
1個のファイルの変更2行の追加5行の削除
  1. 2
    5
      lib/private/legacy/OC_API.php

+ 2
- 5
lib/private/legacy/OC_API.php ファイルの表示

@@ -98,13 +98,10 @@ class OC_API {
}
}

/**
* @return string
*/
public static function requestedFormat() {
public static function requestedFormat(): string {
$formats = ['json', 'xml'];

$format = !empty($_GET['format']) && in_array($_GET['format'], $formats) ? $_GET['format'] : 'xml';
$format = (isset($_GET['format']) && in_array($_GET['format'], $formats)) ? $_GET['format'] : 'xml';
return $format;
}


読み込み中…
キャンセル
保存