akoutmos / doctor

Ensure that your Elixir project documentation is healthy
MIT License
179 stars 15 forks source link

Fix moduledoc detection for older elixir versions #51

Closed djthread closed 2 years ago

djthread commented 2 years ago

I noticed that in my application, the Module Doc column in the report was all Yes even though I know many modules do not have moduledocs. Looking deeper, I notice that module_info.module_doc is returning things like the following, but never :none as doctor is expecting.

:hidden
%{}
%{
  "en" => "This is an actual moduledoc content in our app"
}

The reason seems to be that we've got our app on elixir 1.12.3, and it is apparently giving doctor %{} instead of :none as newer elixirs do.

Is it worthwhile to make a change here to support older versions of elixir? And I'm not sure what :hidden means...

Thanks, Alex !

akoutmos commented 2 years ago

Good catch! Thanks for the fix!