fga-gpp-mds/2017.1-Escola-X

View on GitHub

Showing 3,213 of 3,213 total issues

Tab detected.
Open

end

Tab detected.
Open

if( is_principal? )

Tab detected.
Open

flash[:notice] = "Suspensão alterada com sucesso"

Prefer single-quoted strings when you don't need string interpolation or special symbols.
Open

redirect_to "/errors/error_500"

Use || instead of or.
Open

if ( is_employee? or verify_alumn(id) or is_son?(id) )

Prefer single-quoted strings when you don't need string interpolation or special symbols.
Open

render "suspensions/edit"

Prefer single-quoted strings when you don't need string interpolation or special symbols.
Open

redirect_to "/errors/error_500"
Severity: Minor
Found in app/controllers/users_controller.rb by rubocop

Use 2 (not 3) spaces for indentation.
Open

@alumns = Alumn.all.order('created_at DESC')

Replace class var @@alumn with a class instance var.
Open

@@alumn = Alumn.find(id)

Use a guard clause instead of wrapping the code inside a conditional expression.
Open

if ( !(is_parent_related_to_alumn?(@alumn) or is_me?(@alumn) or is_principal?) )

Prefer single-quoted strings when you don't need string interpolation or special symbols.
Open

flash[:alert] = "Suspensão excluída com sucesso"

Don't use parentheses around the condition of an if.
Open

if ( is_principal? )

Don't use parentheses around a method call.
Open

if ( is_principal? )

Inconsistent indentation detected.
Open

@secretary = Secretary.new

Inconsistent indentation detected.
Open

redirect_to secretaries_path

Space inside parentheses detected.
Open

if ( is_principal? )

Tab detected.
Open

:address,

Space inside parentheses detected.
Open

if ( is_principal? )

Inconsistent indentation detected.
Open

@employee = Employee.new

Space inside parentheses detected.
Open

if ( is_principal? )
Severity
Category
Status
Source
Language