mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
Convert response from add user from XML to JSON
This commit is contained in:
@@ -766,6 +766,20 @@ export class NextCloud implements INodeType {
|
||||
const binaryPropertyName = this.getNodeParameter('binaryPropertyName', i) as string;
|
||||
|
||||
items[i].binary![binaryPropertyName] = await this.helpers.prepareBinaryData(responseData, endpoint);
|
||||
|
||||
} else if (resource === 'user' && operation === 'add') {
|
||||
|
||||
const jsonResponseData: IDataObject = await new Promise((resolve, reject) => {
|
||||
parseString(responseData, { explicitArray: false }, (err, data) => {
|
||||
if (err) {
|
||||
return reject(err);
|
||||
}
|
||||
resolve(data as IDataObject);
|
||||
});
|
||||
});
|
||||
|
||||
returnData.push(jsonResponseData as IDataObject);
|
||||
|
||||
} else if (resource === 'folder' && operation === 'list') {
|
||||
|
||||
const jsonResponseData: IDataObject = await new Promise((resolve, reject) => {
|
||||
|
||||
Reference in New Issue
Block a user