assertIosPlatform function
Throws when the current platform is not TargetPlatform.iOS.
Implementation
void assertIosPlatform(String feature) {
if (defaultTargetPlatform != TargetPlatform.iOS) {
throw UnsupportedError(
'$feature is only supported on iOS (SGPlayer).',
);
}
}