@@ -129,10 +129,10 @@ export class ObjectSerializer {
129
129
*
130
130
* @param data - The value to serialize.
131
131
* @param type - The expected type name as a string.
132
- * @param format - Format hint (e.g. "date" or "date-time").
132
+ * @param format - Format hint (e.g. "date" or "date-time"). Default is an empty string.
133
133
* @returns A JSON-compatible representation of `data`.
134
134
*/
135
- public static serialize ( data : any , type : string , format : string ) : any {
135
+ public static serialize ( data : any , type : string , format : string = "" ) : any {
136
136
if ( data == undefined ) {
137
137
return data ;
138
138
} else if ( primitives . indexOf ( type . toLowerCase ( ) ) !== - 1 ) {
@@ -209,10 +209,10 @@ export class ObjectSerializer {
209
209
*
210
210
* @param data - The raw input to deserialize.
211
211
* @param type - The expected type name as a string.
212
- * @param format - Format hint (e.g. "date" or "date-time").
212
+ * @param format - Format hint (e.g. "date" or "date-time"). Default is an empty string.
213
213
* @returns A deserialized instance or value of `data`.
214
214
*/
215
- public static deserialize ( data : any , type : string , format : string ) : any {
215
+ public static deserialize ( data : any , type : string , format : string = "" ) : any {
216
216
// polymorphism may change the actual type.
217
217
type = ObjectSerializer . findCorrectType ( data , type ) ;
218
218
if ( data == undefined ) {
0 commit comments