Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed dialyser error 'no local return' then definition includes an array #80

Merged
merged 2 commits into from
Oct 12, 2016

Conversation

freke
Copy link
Contributor

@freke freke commented Oct 12, 2016

For the following example dialyzer will currently return the error "no local return" but generate a correct swagger.json file

Properties =
  #{<<"name">> =>
      #{ type => <<"string">>
      ,  description => <<"description">>
      }
  , <<"list">> =>
    #{type => <<"array">>
    , items => #{ type => <<"integer">> }
    }
  },
  ok = cowboy_swagger:add_definition(<<"PropertieName">>, Properties).

this pull request fixes the spec so dialyzer is happy

}}.
-type property_desc() ::
#{ type => binary()
, description => binary()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you add one extra space in these lines so that , is aligned with { and }?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it correct now?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, sir.

@elbrujohalcon elbrujohalcon merged commit 68ce9de into inaka:master Oct 12, 2016
freke added a commit to freke/cowboy-swagger that referenced this pull request Oct 12, 2016
…ray (inaka#80) (#1)

* fixed dialyser error 'no local return' then definition includes an array

* fixed indentation
@freke freke deleted the dialyzer-error-no-local-return branch October 12, 2016 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants