fastcomments-sdk
Version:
FastComments API Client - A SDK for interacting with the FastComments API
73 lines • 3.32 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* fastcomments
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 0.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.instanceOfAPIBanUserChangedValues = instanceOfAPIBanUserChangedValues;
exports.APIBanUserChangedValuesFromJSON = APIBanUserChangedValuesFromJSON;
exports.APIBanUserChangedValuesFromJSONTyped = APIBanUserChangedValuesFromJSONTyped;
exports.APIBanUserChangedValuesToJSON = APIBanUserChangedValuesToJSON;
exports.APIBanUserChangedValuesToJSONTyped = APIBanUserChangedValuesToJSONTyped;
/**
* Check if a given object implements the APIBanUserChangedValues interface.
*/
function instanceOfAPIBanUserChangedValues(value) {
return true;
}
function APIBanUserChangedValuesFromJSON(json) {
return APIBanUserChangedValuesFromJSONTyped(json, false);
}
function APIBanUserChangedValuesFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'id': json['_id'] == null ? undefined : json['_id'],
'tenantId': json['tenantId'] == null ? undefined : json['tenantId'],
'userId': json['userId'] == null ? undefined : json['userId'],
'email': json['email'] == null ? undefined : json['email'],
'username': json['username'] == null ? undefined : json['username'],
'ipHash': json['ipHash'] == null ? undefined : json['ipHash'],
'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
'bannedByUserId': json['bannedByUserId'] == null ? undefined : json['bannedByUserId'],
'bannedCommentText': json['bannedCommentText'] == null ? undefined : json['bannedCommentText'],
'banType': json['banType'] == null ? undefined : json['banType'],
'bannedUntil': json['bannedUntil'] == null ? undefined : (new Date(json['bannedUntil'])),
'hasEmailWildcard': json['hasEmailWildcard'] == null ? undefined : json['hasEmailWildcard'],
'banReason': json['banReason'] == null ? undefined : json['banReason'],
};
}
function APIBanUserChangedValuesToJSON(json) {
return APIBanUserChangedValuesToJSONTyped(json, false);
}
function APIBanUserChangedValuesToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'_id': value['id'],
'tenantId': value['tenantId'],
'userId': value['userId'],
'email': value['email'],
'username': value['username'],
'ipHash': value['ipHash'],
'createdAt': value['createdAt'] == null ? undefined : ((value['createdAt']).toISOString()),
'bannedByUserId': value['bannedByUserId'],
'bannedCommentText': value['bannedCommentText'],
'banType': value['banType'],
'bannedUntil': value['bannedUntil'] == null ? undefined : (value['bannedUntil'].toISOString()),
'hasEmailWildcard': value['hasEmailWildcard'],
'banReason': value['banReason'],
};
}
//# sourceMappingURL=APIBanUserChangedValues.js.map