This commit is contained in:
Simon Knott 2025-02-26 16:35:27 +01:00
parent 250efce52c
commit 1baef032e8
No known key found for this signature in database
GPG key ID: 8CEDC00028084AEC

View file

@ -118,15 +118,12 @@ export const renderAction = (
const { errors, warnings } = modelUtil.stats(action);
const showAttachments = !!action.attachments?.length && !!revealAttachment;
let apiName = action.apiName;
if (apiName === 'apiRequestContext.get')
apiName = 'GET';
else if (apiName === 'apiRequestContext.post')
apiName = 'POST';
else if (apiName === 'apiRequestContext.put')
apiName = 'PUT';
else if (apiName === 'apiRequestContext.delete')
apiName = 'DELETE';
const apiName = {
'apiRequestContext.get': 'GET',
'apiRequestContext.post': 'POST',
'apiRequestContext.put': 'PUT',
'apiRequestContext.delete': 'DELETE',
}[action.apiName] ?? action.apiName;
const parameterString = actionParameterDisplayString(action, sdkLanguage || 'javascript');