mirror of
https://github.com/nuxsmin/sysPass.git
synced 2026-03-07 00:46:59 +01:00
* [MOD] Use static types.
* [MOD] CORS headers. * [MOD] Improve Forwarded header lookup. * [ADD] Create interface for configuration data. Signed-off-by: Rubén D <nuxsmin@syspass.org>
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
*
|
||||
* @author nuxsmin
|
||||
* @link https://syspass.org
|
||||
* @copyright 2012-2020, Rubén Domínguez nuxsmin@$syspass.org
|
||||
* @copyright 2012-2021, Rubén Domínguez nuxsmin@$syspass.org
|
||||
*
|
||||
* This file is part of sysPass.
|
||||
*
|
||||
@@ -19,7 +19,7 @@
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with sysPass. If not, see <http://www.gnu.org/licenses/>.
|
||||
* along with sysPass. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
namespace SP\Modules\Api\Controllers\Help;
|
||||
@@ -39,7 +39,7 @@ trait HelpTrait
|
||||
public static function getHelpFor(string $action): array
|
||||
{
|
||||
if (strpos($action, '/') !== false) {
|
||||
list(, $action) = explode('/', $action);
|
||||
[, $action] = explode('/', $action);
|
||||
}
|
||||
|
||||
if (method_exists(static::class, $action)) {
|
||||
@@ -61,8 +61,10 @@ trait HelpTrait
|
||||
private static function getItem(
|
||||
string $name,
|
||||
string $description,
|
||||
bool $required = false): array
|
||||
bool $required = false): array
|
||||
{
|
||||
return [$name => ['description' => $description, 'required' => $required]];
|
||||
return [
|
||||
$name => ['description' => $description, 'required' => $required]
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user