diff --git a/lib/sweet_xml.ex b/lib/sweet_xml.ex index 8d3646e..82f7855 100644 --- a/lib/sweet_xml.ex +++ b/lib/sweet_xml.ex @@ -704,7 +704,7 @@ defmodule SweetXml do Whenever you are working with some xml that was not generated by your system, it is highly recommended that you restrain some functionalities of XML - during the parsing. SweetXml allows in particular to prevent DTD parsing and fetching. + during the parsing. `SweetXml` allows in particular to prevent DTD parsing and fetching. Unless you know exactly what kind of DTD you want to permit in your xml, it is recommended that you use the following code example to prevent possible attacks: ``` @@ -714,7 +714,7 @@ defmodule SweetXml do ``` For more details, see `parse/2`. """ - @spec xmap(parent :: (doc | xmlElement), mapping :: specs, options :: (boolean | map)) :: (map | keyword) + @spec xmap(parent :: (doc | xmlElement | nil), mapping :: specs, options :: (boolean | map)) :: (map | keyword | nil) when specs: keyword(spec | specs) def xmap(parent, mapping, options \\ false) diff --git a/mix.exs b/mix.exs index 93ab9d4..f616fef 100644 --- a/mix.exs +++ b/mix.exs @@ -40,7 +40,7 @@ defmodule SweetXml.Mixfile do main: "readme", source_url: source_url(), # We need to git tag with the corresponding format. - source_ref: "v#{version()}", + source_ref: "v#{version()}" ] end @@ -56,7 +56,7 @@ defmodule SweetXml.Mixfile do licenses: ["MIT"], links: %{ "Changelog" => "https://hexdocs.pm/#{app()}/changelog.html", - "GitHub" => source_url(), + "GitHub" => source_url() } ] end diff --git a/mix.lock b/mix.lock index 7f07d42..94c9926 100644 --- a/mix.lock +++ b/mix.lock @@ -1,6 +1,8 @@ %{ + "dialyxir": {:hex, :dialyxir, "1.4.3", "edd0124f358f0b9e95bfe53a9fcf806d615d8f838e2202a9f430d59566b6b53b", [:mix], [{:erlex, ">= 0.2.6", [hex: :erlex, repo: "hexpm", optional: false]}], "hexpm", "bf2cfb75cd5c5006bec30141b131663299c661a864ec7fbbc72dfa557487a986"}, "earmark": {:hex, :earmark, "1.3.1", "73812f447f7a42358d3ba79283cfa3075a7580a3a2ed457616d6517ac3738cb9", [:mix], [], "hexpm", "000aaeff08919e95e7aea13e4af7b2b9734577b3e6a7c50ee31ee88cab6ec4fb"}, "earmark_parser": {:hex, :earmark_parser, "1.4.25", "2024618731c55ebfcc5439d756852ec4e85978a39d0d58593763924d9a15916f", [:mix], [], "hexpm", "56749c5e1c59447f7b7a23ddb235e4b3defe276afc220a6227237f3efe83f51e"}, + "erlex": {:hex, :erlex, "0.2.6", "c7987d15e899c7a2f34f5420d2a2ea0d659682c06ac607572df55a43753aa12e", [:mix], [], "hexpm", "2ed2e25711feb44d52b17d2780eabf998452f6efda104877a3881c2f8c0c0c75"}, "ex_doc": {:hex, :ex_doc, "0.28.3", "6eea2f69995f5fba94cd6dd398df369fe4e777a47cd887714a0976930615c9e6", [:mix], [{:earmark_parser, "~> 1.4.19", [hex: :earmark_parser, repo: "hexpm", optional: false]}, {:makeup_elixir, "~> 0.14", [hex: :makeup_elixir, repo: "hexpm", optional: false]}, {:makeup_erlang, "~> 0.1", [hex: :makeup_erlang, repo: "hexpm", optional: false]}], "hexpm", "05387a6a2655b5f9820f3f627450ed20b4325c25977b2ee69bed90af6688e718"}, "makeup": {:hex, :makeup, "1.1.0", "6b67c8bc2882a6b6a445859952a602afc1a41c2e08379ca057c0f525366fc3ca", [:mix], [{:nimble_parsec, "~> 1.2.2 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "0a45ed501f4a8897f580eabf99a2e5234ea3e75a4373c8a52824f6e873be57a6"}, "makeup_elixir": {:hex, :makeup_elixir, "0.16.0", "f8c570a0d33f8039513fbccaf7108c5d750f47d8defd44088371191b76492b0b", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}, {:nimble_parsec, "~> 1.2.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "28b2cbdc13960a46ae9a8858c4bebdec3c9a6d7b4b9e7f4ed1502f8159f338e7"},