src/UploadHandlerBuilder.php
public function allowExtensions($extensions)
    {
        if (!is_array($extensions)) {
            $extensions = [$extensions];
        }
        $this->constraints[] = new ExtensionConstraint($extensions);
        return $this;
    }
public function allowExtensions($extensions)
    {
        if (!is_array($extensions)) {
            $extensions = [$extensions];
        }
        $this->constraints[] = new ExtensionConstraint($extensions);
        return $this;
    }
Set allowed extensions

@param array|string $extensions
@return $this