mirror of
https://github.com/Drop-OSS/drop
synced 2026-08-27 14:23:05 -04:00
15 lines
319 B
TypeScript
15 lines
319 B
TypeScript
import { Platform } from "~/prisma/client";
|
|
|
|
export function parsePlatform(platform: string) {
|
|
switch (platform.toLowerCase()) {
|
|
case "linux":
|
|
return Platform.Linux;
|
|
case "windows":
|
|
return Platform.Windows;
|
|
case "mac":
|
|
case "macos":
|
|
return Platform.macOS;
|
|
}
|
|
|
|
return undefined;
|
|
}
|