code: public function getAllowedTypes($asArray = false)
      {
          $types = $this->getAttribute('data-allowedtypes');
  
          if ($asArray) {
              return explode(',', $types);
          }
  
          return $types;
      }
docs: Gets the allowed mimetypes
  
  @param bool $asArray if true, the types are returned as an array,
  if false, the types are returned as comma separated string.
  
  @return string|array