@@ -156,10 +156,10 @@ export class ObjectSerializer {
156
156
*
157
157
* @param data - The value to serialize.
158
158
* @param type - The expected type name as a string.
159
- * @param format - Format hint (e.g. "date" or "date-time").
159
+ * @param format - Format hint (e.g. "date" or "date-time"). Default is an empty string.
160
160
* @returns A JSON-compatible representation of `data`.
161
161
*/
162
- public static serialize ( data : any , type : string , format : string ) : any {
162
+ public static serialize ( data : any , type : string , format : string = "" ) : any {
163
163
if ( data == undefined ) {
164
164
return data ;
165
165
} else if ( primitives . indexOf ( type . toLowerCase ( ) ) !== - 1 ) {
@@ -236,10 +236,10 @@ export class ObjectSerializer {
236
236
*
237
237
* @param data - The raw input to deserialize.
238
238
* @param type - The expected type name as a string.
239
- * @param format - Format hint (e.g. "date" or "date-time").
239
+ * @param format - Format hint (e.g. "date" or "date-time"). Default is an empty string.
240
240
* @returns A deserialized instance or value of `data`.
241
241
*/
242
- public static deserialize ( data : any , type : string , format : string ) : any {
242
+ public static deserialize ( data : any , type : string , format : string = "" ) : any {
243
243
// polymorphism may change the actual type.
244
244
type = ObjectSerializer . findCorrectType ( data , type ) ;
245
245
if ( data == undefined ) {
0 commit comments