howood/imagereductor

View on GitHub
application/validator/imagevalidator.go

Summary

Maintainability
A
35 mins
Test Coverage

Method ImageValidator.Validate has 5 return statements (exceeds 4 allowed).
Open

func (val *ImageValidator) Validate(uploadfile io.Reader) error {
    imageinfo, format, err := image.DecodeConfig(uploadfile)
    log.Debug(val.ctx, fmt.Sprintf("%#v", imageinfo))
    log.Debug(val.ctx, format)
    if err != nil {
Severity: Major
Found in application/validator/imagevalidator.go - About 35 mins to fix

    There are no issues that match your filters.

    Category
    Status