( pluginId: string, )
| 69 | } |
| 70 | |
| 71 | export async function installPerPluginLimit( |
| 72 | pluginId: string, |
| 73 | ): Promise<LimitResult> { |
| 74 | const ip = getIpFromHeaders(await getRequestHeaders()); |
| 75 | return check({ |
| 76 | rateLimitId: RATE_LIMIT_IDS.installPerPlugin, |
| 77 | rateLimitKey: `${ip}:${pluginId}`, |
| 78 | }); |
| 79 | } |
| 80 | |
| 81 | export async function installGlobalLimit(): Promise<LimitResult> { |
| 82 | return check({ rateLimitId: RATE_LIMIT_IDS.installGlobal }); |
no test coverage detected