Check plugin available when add Cordova plugin to Outsystems

Hi,

I follow the documentation to add a Cordova plugin to Outsystems.

https://www.outsystems.com/blog/posts/how-to-create-a-cordova-plugin-from-scratch/
In the example with the ToastyPlugin, in the check plugin available method, the code is:
$parameters.IsAvailable = false;

if (typeof(window.plugins) !== 'undefined')

 {  $parameters.IsAvailable = typeof(window.plugins.toastyPlugin) !== 'undefined';}

The question is, how do we check plugin available if the plugin doesn't assign the plugin variable to window.plugins.
For example, how do we check plugin variable for this plugin below:
https://github.com/vmfo22/wikitude-cordova-plugin/

/* Export a new WikitudePlugin instance */

var wikitudePlugin = new WikitudePlugin();

module.exports = wikitudePlugin;


Maybe try checking if the wikitudePlugin variable remains undefined after you initialize it. If it is then the plugin probably isn't available.