It looks like NAV (C/Side) does not check if an object ID is used in an extension.
I've created codeunit 50250 in an extension and published it. Works fine.
When I then create codeunit 50250 in C/Side NAV uses that one instead.
After deleting the codeunit in C/Side it deletes the metadata and you have to re-publish your extension.
The desired way would be that C/Side checks if an extension is using that ID and raises an error. This is how V1 behaved if I remember correctly.
Merry x-mas.
I am not sure we are going to fix this one though.
Here is a workaround. https://markbrummel.blog/2018/05/01/prevent-c-side-from-using-ids-used-by-extensions/
Most helpful comment
Here is a workaround. https://markbrummel.blog/2018/05/01/prevent-c-side-from-using-ids-used-by-extensions/