Hi group, This all started yesterday when a module I created in an environment with the RM module installed failed to load in another environment without the RM module. I had introduced a conditional function that was only supposed to run if the RecMan modue was installed. However, it seems that even referencing the RM global is enough to create the dependency. For instance, this code block:
// Exit immediately if RM module not insalled
if !IsDefined( $RecMan )
retVal.ok = ok
retVal.errMsg = errMsg
retVal.apiError = apiError
return retval
end
Seemed to be enough to create a dependency in my module (and even in the export file). The only other RM code that was present was this:
Dynamic RMSessionData = $LLIAPI.SessionDataSubsystem.GetItem( "RecManSessionData")
response.data.rmsettings = Assoc.CreateAssoc()
response.data.rmsettings.RMClassInherit = RMSessionData.fRMClassInherit
Since these are all valid Oscript data types, the above shouldn't have caused the dependency, and after I removed it (the second section) first, I still had the dependency.
If I wanted to create a module that will interact with the RM module if it is present, but not depend on it, is there a correct way of doing this?
Thanks in advance
-Hugh Ferguson