File tree Expand file tree Collapse file tree 1 file changed +1
-3
lines changed
shopify_function_macro/src Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -157,7 +157,7 @@ impl Parse for ShopifyFunctionTargetArgs {
157157 } else if lookahead. peek ( kw:: output_stream) {
158158 args. output_stream = Some ( Self :: parse :: < kw:: output_stream , Expr > ( & input) ?) ;
159159 } else {
160- panic ! ( "Unknown shopify_function_target parameter" ) ;
160+ return Err ( lookahead . error ( ) ) ;
161161 }
162162 }
163163 Ok ( args)
@@ -211,12 +211,10 @@ pub fn shopify_function_target(
211211 let target_handle_string = args. target . map_or ( function_name_string. clone ( ) , |target| {
212212 target
213213 . value ( )
214- . to_string ( )
215214 . split ( '.' )
216215 . collect :: < Vec < & str > > ( )
217216 . last ( )
218217 . unwrap ( )
219- . to_string ( )
220218 . to_case ( Case :: Snake )
221219 } ) ;
222220 let module_name = args. module_name . map_or (
You can’t perform that action at this time.
0 commit comments