@@ -24,7 +24,8 @@ pub struct DscExtension {
24
24
/// The capabilities of the resource.
25
25
pub capabilities : Vec < Capability > ,
26
26
/// The extensions supported for importing.
27
- pub import_extensions : Option < Vec < String > > ,
27
+ #[ serde( rename = "importFileExtensions" ) ]
28
+ pub import_file_extensions : Option < Vec < String > > ,
28
29
/// The file path to the resource.
29
30
pub path : String ,
30
31
/// The description of the resource.
@@ -65,7 +66,7 @@ impl DscExtension {
65
66
type_name : String :: new ( ) ,
66
67
version : String :: new ( ) ,
67
68
capabilities : Vec :: new ( ) ,
68
- import_extensions : None ,
69
+ import_file_extensions : None ,
69
70
description : None ,
70
71
path : String :: new ( ) ,
71
72
directory : String :: new ( ) ,
@@ -153,7 +154,7 @@ impl DscExtension {
153
154
if self . capabilities . contains ( & Capability :: Import ) {
154
155
let file_path = Path :: new ( file) ;
155
156
let file_extension = file_path. extension ( ) . and_then ( |s| s. to_str ( ) ) . unwrap_or_default ( ) . to_string ( ) ;
156
- if self . import_extensions . as_ref ( ) . is_some_and ( |exts| exts. contains ( & file_extension) ) {
157
+ if self . import_file_extensions . as_ref ( ) . is_some_and ( |exts| exts. contains ( & file_extension) ) {
157
158
debug ! ( "{}" , t!( "extensions.dscextension.importingFile" , file = file, extension = self . type_name) ) ;
158
159
} else {
159
160
debug ! ( "{}" , t!( "extensions.dscextension.importNotSupported" , file = file, extension = self . type_name) ) ;
0 commit comments