diff --git a/.changeset/fifty-ducks-vanish.md b/.changeset/fifty-ducks-vanish.md new file mode 100644 index 0000000000000..51d35b02742fb --- /dev/null +++ b/.changeset/fifty-ducks-vanish.md @@ -0,0 +1,5 @@ +--- +"@rocket.chat/meteor": patch +--- + +Adds deprecation warning on `saveCannedResponse` diff --git a/apps/meteor/ee/app/canned-responses/server/methods/saveCannedResponse.ts b/apps/meteor/ee/app/canned-responses/server/methods/saveCannedResponse.ts index 8aea7a8925aae..86a605fdaf781 100644 --- a/apps/meteor/ee/app/canned-responses/server/methods/saveCannedResponse.ts +++ b/apps/meteor/ee/app/canned-responses/server/methods/saveCannedResponse.ts @@ -5,6 +5,7 @@ import { Match, check } from 'meteor/check'; import { Meteor } from 'meteor/meteor'; import { hasPermissionAsync } from '../../../../../app/authorization/server/functions/hasPermission'; +import { methodDeprecationLogger } from '../../../../../app/lib/server/lib/deprecationWarningLogger'; import notifications from '../../../../../app/notifications/server/lib/Notifications'; type ResponseData = { @@ -122,6 +123,7 @@ export const saveCannedResponse = async ( Meteor.methods({ async saveCannedResponse(_id, responseData) { + methodDeprecationLogger.method('saveCannedResponse', '8.0.0', 'POST /v1/canned-responses'); const userId = Meteor.userId(); if (!userId) { throw new Meteor.Error('error-not-allowed', 'Not allowed', { method: 'saveCannedResponse' });