mirror of
https://github.com/laurent22/joplin.git
synced 2024-12-18 09:35:20 +02:00
13 lines
289 B
TypeScript
13 lines
289 B
TypeScript
|
|
const validatePluginPlatforms = (platforms: string[]) => {
|
|
if (!platforms) {
|
|
return;
|
|
}
|
|
|
|
if (!Array.isArray(platforms) || platforms.some(p => typeof p !== 'string')) {
|
|
throw new Error('If specified, platforms must be a string array');
|
|
}
|
|
};
|
|
|
|
export default validatePluginPlatforms;
|