public function getErrorMessage(UploadedFile $file)
    {
        $message = null;
        if ($this->minSize && $this->maxSize) {
            $message = sprintf('File size should between %s and %s', $this->minSize, $this->maxSize);
        } elseif ($this->minSize === null) {
            $message = sprintf('File size should less than %s', $this->maxSize);
        } elseif ($this->maxSize === null) {
            $message = sprintf('File size should greater than %s', $this->minSize);
        }
        return $message;
    }
public function getErrorMessage(UploadedFile $file)
    {
        $message = null;
        if ($this->minSize && $this->maxSize) {
            $message = sprintf('File size should between %s and %s', $this->minSize, $this->maxSize);
        } elseif ($this->minSize === null) {
            $message = sprintf('File size should less than %s', $this->maxSize);
        } elseif ($this->maxSize === null) {
            $message = sprintf('File size should greater than %s', $this->minSize);
        }
        return $message;
    }
{@inheritdoc}