Skip to content

Commit

Permalink
Merge pull request #89 from kianmeng/fix-typos-and-prettify-md-yml-files
Browse files Browse the repository at this point in the history
Fix typos and prettify md/yaml files
  • Loading branch information
half-shell authored Mar 19, 2024
2 parents 27a193f + 7920a40 commit 480441f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@

### Changed

* Handling the option `{:rules, _}` ourselve, as well as partially the option `{:rules, _, _, _}`.
* Handling the option `{:rules, _}` ourselves, as well as partially the option `{:rules, _, _, _}`.
When nothing is given, a new table is created, and destroyed after.
If a table is given, and a DTD option is chosen, the table is reused for the DTD handling.
If a custom `{:rules, _, _, _}` is given, and a restrictive DTD option is chosen, the custome rule will be overriden.
If a custom `{:rules, _, _, _}` is given, and a restrictive DTD option is chosen, the custome rule will be overridden.
Because of this mutual exclusivity (reconciling the behaviors is not possible via composition), it is recommended that you handle the DTD
problem by yourself. You can see the issue `#71` for ideas.
See the issue `#41` for more details on why this change happened. (Ets leaks.)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -489,5 +489,5 @@ SweetXml source code is licensed under the [MIT License](https://github.com/kbrw
# CONTRIBUTING

Hi, and thank you for wanting to contribute.
Please refer to the centralized informations available at: https://github.com/kbrw#contributing
Please refer to the centralized information available at: https://github.com/kbrw#contributing

4 changes: 2 additions & 2 deletions lib/sweet_xml/options.ex
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
defmodule SweetXml.Options do
### WARNING:
# This is an intenal api, use at your own risk.
# This is an internal api, use at your own risk.

@moduledoc false

Expand Down Expand Up @@ -104,7 +104,7 @@ defmodule SweetXml.Options do

{[[_]], _opts} ->
require Logger
_ = Logger.warning("rules opt will be overriden because of the dtd option")
_ = Logger.warning("rules opt will be overridden because of the dtd option")
opts = opts ++ dtd_opts ++ [rules: ets]
{opts, {:cleanup, ets}}
end
Expand Down
2 changes: 1 addition & 1 deletion test/issue_41_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ defmodule Issue41Test do
# Warning ! Sensitive to async tests.
assert capture_log(fn ->
SweetXml.parse("<tag></tag>", [rules, dtd: :none])
end) =~ "rules opt will be overriden because of the dtd option"
end) =~ "rules opt will be overridden because of the dtd option"
end

test "keeps our rules/1" do
Expand Down

0 comments on commit 480441f

Please sign in to comment.