()
| 78 | } |
| 79 | |
| 80 | const getDecodedOfflineLicense = (): getValidOfflineLicense | null => { |
| 81 | const licenseKey = env.SOURCEBOT_EE_LICENSE_KEY; |
| 82 | if (!licenseKey || !licenseKey.startsWith(offlineLicensePrefix)) { |
| 83 | return null; |
| 84 | } |
| 85 | |
| 86 | return decodeOfflineLicenseKeyPayload(licenseKey.substring(offlineLicensePrefix.length)); |
| 87 | } |
| 88 | |
| 89 | const getValidOfflineLicense = (): getValidOfflineLicense | null => { |
| 90 | const payload = getDecodedOfflineLicense(); |
no test coverage detected