(current: string, minimum: string)
| 89 | } |
| 90 | |
| 91 | function compareVersions(current: string, minimum: string): boolean { |
| 92 | const c = current.split('.').map(Number); |
| 93 | const m = minimum.split('.').map(Number); |
| 94 | for (let i = 0; i < Math.max(c.length, m.length); i++) { |
| 95 | const cv = c[i] || 0; |
| 96 | const mv = m[i] || 0; |
| 97 | if (cv > mv) return true; |
| 98 | if (cv < mv) return false; |
| 99 | } |
| 100 | return true; |
| 101 | } |
| 102 | |
| 103 | export interface HealthResponse { |
| 104 | status: string; |