@@ -756,10 +756,10 @@ export class ObjectSerializer {
756
756
*
757
757
* @param data - The value to serialize.
758
758
* @param type - The expected type name as a string.
759
- * @param format - Format hint (e.g. "date" or "date-time").
759
+ * @param format - Format hint (e.g. "date" or "date-time"). Default is an empty string.
760
760
* @returns A JSON-compatible representation of `data`.
761
761
*/
762
- public static serialize ( data : any , type : string , format : string ) : any {
762
+ public static serialize ( data : any , type : string , format : string = "" ) : any {
763
763
if ( data == undefined ) {
764
764
return data ;
765
765
} else if ( primitives . indexOf ( type . toLowerCase ( ) ) !== - 1 ) {
@@ -836,10 +836,10 @@ export class ObjectSerializer {
836
836
*
837
837
* @param data - The raw input to deserialize.
838
838
* @param type - The expected type name as a string.
839
- * @param format - Format hint (e.g. "date" or "date-time").
839
+ * @param format - Format hint (e.g. "date" or "date-time"). Default is an empty string.
840
840
* @returns A deserialized instance or value of `data`.
841
841
*/
842
- public static deserialize ( data : any , type : string , format : string ) : any {
842
+ public static deserialize ( data : any , type : string , format : string = "" ) : any {
843
843
// polymorphism may change the actual type.
844
844
type = ObjectSerializer . findCorrectType ( data , type ) ;
845
845
if ( data == undefined ) {
0 commit comments