Dynamics 365 Business Central on-premise: checking extension’s status via Powershell

An interesting question pops out yesterday: with Dynamics 365 Business Central on-premise, how can I programmatically check if a particular extension is installed or not? The standard Powershell command (in the Microsoft.Dynamics.Nav.Apps.Management module) that gets informations about an extension in a specified Business Central Server instance…