Coding standards
Security in ResourceSpace
Developer reference
Database
User api session functions
Geolocation functions
Storage test functions

storage_test_allowed()

Description

Can the current authenticated administrator run installation storage diagnostics?

Parameters

ColumnTypeDefaultDescription
bool { :
$username
$anonymous_login
$k;
get_temp_dir. never
stream but
'://'

Return

bool False for external shares and anonymous sessions, including anonymous administrators.

Location

include/storage_test_functions.php lines 8 to 13

Definition

 
function storage_test_allowed(): bool
{
    global 
$userref, $username, $anonymous_login, $k;
    return isset(
$userref) && $userref > 0 && checkperm('a') && empty($k)
        && (!isset(
$anonymous_login) || $username !== $anonymous_login);
}

This article was last updated 13th November 2026 16:05 Europe/London time based on the source file dated 13th November 2026 11:40 Europe/London time.