code change · fixAdministration & Setupofficial - Microsoftreviewed - checked by Opus

#13572 Fix cloud migration company delete removing the wrong hybrid company

Cloud migration company deletion now removes the correct hybrid company and intelligent cloud status records instead of potentially deleting records for unrelated companies. The webhook subscription is moved to the first remaining company when the subscribed company is deleted.

Pull request · merged into main (BC30) on 2026-11-10 by darjoo · 2 files (+201 -22), 1 AL · fix · tier official · reviewed (checked by Opus)

What changed

  • HandleCompanyDelete now uses the deleted company (Rec) instead of a local Company variable to identify which records to remove
  • Webhook handling refactored into separate methods IsCompanyWebhookCompany and MoveWebhookSubscription
  • Webhook moves to first remaining company to keep cloud migration subscriptions functional
  • Fixes issue where deleting the company holding webhook subscription caused deletion of wrong hybrid company records
  • Tests added for company deletion and webhook transfer scenarios
  • Behaviour changes for users or extensions.

AL objects touched

Also merged into

  • #13896 into releases/29.x on 2026-11-10

Context

  • Work items: AB#657775
  • Labels: AL: Apps (W1), Team: Integrations
  • Systems: administration

No source states these links: they share an object, a model read them, or a person found the same subject.

Source: metadata of a merged pull request in microsoft/BCApps (bcapps): title, labels, changed paths and counts, with a summary in our words. No source text and no description beyond one short quote (D10, D61).