public function getUploadFieldName($field = null)
    {
        if (!is_null($field)) {
            return $field;
        }

        $imagesFields = $this->getDefinedUploadFields();
        $fieldKey = array_first(array_keys($imagesFields));

        // return first field name
        return is_int($fieldKey)
            ? $imagesFields[$fieldKey]
            : $fieldKey;
    }
public function getUploadFieldName($field = null)
    {
        if (!is_null($field)) {
            return $field;
        }

        $imagesFields = $this->getDefinedUploadFields();
        $fieldKey = array_first(array_keys($imagesFields));

        // return first field name
        return is_int($fieldKey)
            ? $imagesFields[$fieldKey]
            : $fieldKey;
    }
public function getUploadFieldName ( $ field = null ) { if ( ! is_null ( $ field ) ) { return $ field ; } $ imagesFields = $ this -> getDefinedUploadFields ( ) ; $ fieldKey = array_first ( array_keys ( $ imagesFields ) ) ; // return first field name return is_int ( $ fieldKey ) ? $ imagesFields [ $ fieldKey ] : $ fieldKey ; }
Get the upload field name

@param null $field
@return mixed|null
Get the upload field name