Fix for generic activator.createinstance