private function applyPrefix(array $array, $prefix = null)
    {
        if ($prefix === null) {
            return $array;
        }

        $result = [];
        foreach ($array as $key => $value) {
            $result[$prefix . self::PREFIX_GLUE . $key] = $value;
        }

        return $result;
    }
private function applyPrefix(array $array, $prefix = null)
    {
        if ($prefix === null) {
            return $array;
        }

        $result = [];
        foreach ($array as $key => $value) {
            $result[$prefix . self::PREFIX_GLUE . $key] = $value;
        }

        return $result;
    }
private function applyPrefix ( array $ array , $ prefix = null ) { if ( $ prefix === null ) { return $ array ; } $ result = [ ] ; foreach ( $ array as $ key => $ value ) { $ result [ $ prefix . self :: PREFIX_GLUE . $ key ] = $ value ; } return $ result ; }
Applies prefix to array keys

@param array       $array
@param null|string $prefix

@return array
Applies prefix to array keys