Skip to content

Commit eeb3af8

Browse files
NSHkrNSHkr
authored andcommitted
Release 0.1.1
1 parent 69e4dc3 commit eeb3af8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/json_remedy.ex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ defmodule JsonRemedy do
6565
iex> JsonRemedy.repair(~s|[1, 2, 3,]|, logging: true)
6666
{:ok, [1, 2, 3], [%{layer: :layer3, action: "removed trailing comma"}]}
6767
68-
iex> JsonRemedy.repair(~s|```json\n{"valid": true}\n```|)
68+
iex> JsonRemedy.repair(~s/```json\\n{"valid": true}\\n```/)
6969
{:ok, %{"valid" => true}}
7070
"""
7171
@spec repair(binary(), [option()]) :: repair_result() | repair_result_with_logs()
@@ -113,7 +113,7 @@ defmodule JsonRemedy do
113113
iex> JsonRemedy.repair_to_string(~s|[1, 2, 3,]|)
114114
{:ok, "[1,2,3]"}
115115
116-
iex> JsonRemedy.repair_to_string(~s|```json\n{"test": true}\n```|)
116+
iex> JsonRemedy.repair_to_string(~s/```json\\n{"test": true}\\n```/)
117117
{:ok, ~s|{"test":true}|}
118118
"""
119119
@spec repair_to_string(binary(), [option()]) :: {:ok, binary()} | {:error, String.t()}
@@ -195,7 +195,7 @@ defmodule JsonRemedy do
195195
iex> JsonRemedy.can_repair?(~s|{name: "Alice"}|)
196196
true
197197
198-
iex> JsonRemedy.can_repair?(~s|```json\n{"test": true}\n```|)
198+
iex> JsonRemedy.can_repair?(~s/```json\\n{"test": true}\\n```/)
199199
true
200200
"""
201201
@spec can_repair?(binary()) :: boolean()

0 commit comments

Comments
 (0)