File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 1- use htmd:: { HtmlToMarkdown , options:: * } ;
2- use rustler:: { Atom , NifResult , NifTuple , NifStruct } ;
1+ use htmd:: { options:: * , HtmlToMarkdown } ;
2+ use rustler:: { Atom , NifResult , NifStruct , NifTuple } ;
33
44mod atoms {
55 rustler:: atoms! {
@@ -195,7 +195,6 @@ impl From<ConvertOptions> for Options {
195195 options. bullet_list_marker = bullet_list_marker_from_atom ( bullet_list_marker) ;
196196 }
197197
198-
199198 if let Some ( preformatted_code) = opts. preformatted_code {
200199 options. preformatted_code = preformatted_code;
201200 }
@@ -204,7 +203,7 @@ impl From<ConvertOptions> for Options {
204203 }
205204}
206205
207- #[ rustler:: nif]
206+ #[ rustler:: nif( schedule = "DirtyCpu" ) ]
208207fn convert ( html : String ) -> NifResult < Response > {
209208 let converter = HtmlToMarkdown :: new ( ) ;
210209 match converter. convert ( & html) {
@@ -219,7 +218,7 @@ fn convert(html: String) -> NifResult<Response> {
219218 }
220219}
221220
222- #[ rustler:: nif]
221+ #[ rustler:: nif( schedule = "DirtyCpu" ) ]
223222fn convert_with_options ( html : String , options : ConvertOptions ) -> NifResult < Response > {
224223 // Extract skip_tags before moving options
225224 let skip_tags = options. skip_tags . clone ( ) ;
You can’t perform that action at this time.
0 commit comments