@@ -93,20 +93,20 @@ private bool TryHandlePaginationMethodWithOptions(MethodProvider method)
9393 {
9494 newParameters . Insert (
9595 lastRemovedIndex ,
96- new ParameterProvider ( "options" , $ "The pagination options", optionsType . Type , defaultValue : new KeywordExpression ( "default" , null ) ) ) ;
96+ new ParameterProvider ( "options" , $ "The pagination options", optionsType . Type , defaultValue : Snippet . Default ) ) ;
9797
9898 var newSignature = new MethodSignature (
99- methodSignature . Name ,
100- methodSignature . Description ,
101- methodSignature . Modifiers ,
102- methodSignature . ReturnType ,
103- methodSignature . ReturnDescription ,
104- newParameters ,
105- methodSignature . Attributes ,
106- methodSignature . GenericArguments ,
107- methodSignature . GenericParameterConstraints ,
108- methodSignature . ExplicitInterface ,
109- methodSignature . NonDocumentComment ) ;
99+ methodSignature . Name ,
100+ methodSignature . Description ,
101+ methodSignature . Modifiers ,
102+ methodSignature . ReturnType ,
103+ methodSignature . ReturnDescription ,
104+ newParameters ,
105+ methodSignature . Attributes ,
106+ methodSignature . GenericArguments ,
107+ methodSignature . GenericParameterConstraints ,
108+ methodSignature . ExplicitInterface ,
109+ methodSignature . NonDocumentComment ) ;
110110
111111 var optionsParam = newParameters [ lastRemovedIndex ] ;
112112
@@ -212,7 +212,7 @@ binaryExpr.Right is KeywordExpression rightKeyword &&
212212 var hasMoreNullCheck = new BinaryOperatorExpression (
213213 "==" ,
214214 new MemberExpression ( null , "hasMore" ) ,
215- new KeywordExpression ( "false" , null ) ) ;
215+ Snippet . False ) ;
216216
217217 // Return "nextToken == null || hasMore == null"
218218 return new BinaryOperatorExpression ( "||" , binaryExpr , hasMoreNullCheck ) ;
@@ -244,7 +244,7 @@ assignmentExpression.Value is MemberExpression memberExpression &&
244244 new MemberExpression ( memberExpression . Inner , "HasMore" ) ) ;
245245
246246 // Insert the new assignment before the existing one
247- statementList . Insert ( i , new ExpressionStatement ( hasMoreAssignment ) ) ;
247+ statementList . Insert ( i , hasMoreAssignment . Terminate ( ) ) ;
248248 statementList . Insert ( i , new SingleLineCommentStatement ( "Plugin customization: add hasMore assignment" ) ) ;
249249 var updatedWhileStatement = new WhileStatement ( whileStatement . Condition ) ;
250250 foreach ( MethodBodyStatement bodyStatement in statementList )
0 commit comments