File tree 1 file changed +17
-14
lines changed 1 file changed +17
-14
lines changed Original file line number Diff line number Diff line change @@ -141,20 +141,23 @@ class ServerlessStepFunctions {
141
141
. then ( this . display ) ,
142
142
} ;
143
143
144
- const stepFunctionsSchema = {
145
- type : 'object' ,
146
- properties : {
147
- stateMachines : { type : 'object' } ,
148
- validate : { type : 'boolean' } ,
149
- noOutput : { type : 'boolean' } ,
150
- activities : { type : 'array' } ,
151
- } ,
152
- required : [ 'stateMachines' ] ,
153
- } ;
154
- this . serverless . configSchemaHandler . defineTopLevelProperty (
155
- 'stepFunctions' ,
156
- stepFunctionsSchema ,
157
- ) ;
144
+ // relevant since sls v1.78.0
145
+ if ( this . serverless . configSchemaHandler ) {
146
+ const stepFunctionsSchema = {
147
+ type : 'object' ,
148
+ properties : {
149
+ stateMachines : { type : 'object' } ,
150
+ validate : { type : 'boolean' } ,
151
+ noOutput : { type : 'boolean' } ,
152
+ activities : { type : 'array' } ,
153
+ } ,
154
+ required : [ 'stateMachines' ] ,
155
+ } ;
156
+ this . serverless . configSchemaHandler . defineTopLevelProperty (
157
+ 'stepFunctions' ,
158
+ stepFunctionsSchema ,
159
+ ) ;
160
+ }
158
161
}
159
162
160
163
invoke ( ) {
You can’t perform that action at this time.
0 commit comments