Gildas Garcia
43300d43ce
chore: consolidate useAPIKeysQuery + getKeys into a single useAPIKeys hook ( #46761 )
...
## Problem
- API may return a non-array shape that can crash `getKeys` because of
an hard coded cast
- getting API keys is cumbersome as consumers have to call two functions
## Solution
- consolidate `useAPIKeysQuery` + `getKeys` into a single `useAPIKeys`
hook
- guard `getKeys` so that it doesn't crash if passed a non array value
- update usages
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **Refactor**
* Unified how project API keys are retrieved across the studio,
resulting in more consistent loading/error handling and slight
responsiveness improvements when showing keys and related command
snippets. UI and permissions behavior remain unchanged for end users.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-06-09 15:49:10 +02:00
..
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-05-14 15:12:08 -04:00
2026-05-22 10:01:54 +02:00
2026-06-08 10:51:04 -06:00
2026-06-09 15:49:10 +02:00
2026-05-05 12:02:52 -04:00
2026-06-05 14:44:11 -04:00
2026-04-03 09:15:57 +02:00
2026-04-20 10:33:56 +10:00
2026-06-04 15:34:59 +02:00
2026-04-03 09:15:57 +02:00
2026-06-01 08:02:22 -06:00
2026-05-04 13:08:06 -04:00
2026-04-03 09:15:57 +02:00
2026-05-15 16:41:58 +08:00
2026-05-15 14:50:38 -04:00
2026-05-14 15:12:08 -04:00
2026-05-06 12:21:48 -04:00
2026-05-06 12:21:48 -04:00
2026-04-03 09:15:57 +02:00
2026-05-15 12:08:20 -04:00
2026-05-06 12:21:48 -04:00
2026-05-06 12:21:48 -04:00
2026-05-15 12:08:20 -04:00
2026-05-06 10:53:49 +08:00
2026-05-06 12:21:48 -04:00
2026-04-03 09:15:57 +02:00
2026-05-13 16:07:10 +00:00
2026-04-03 09:15:57 +02:00
2026-04-21 16:38:03 +12:00
2026-05-28 10:30:57 -04:00
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-04-27 17:42:34 +08:00
2026-04-27 17:42:34 +08:00
2026-04-03 09:15:57 +02:00
2026-05-13 16:07:10 +00:00
2026-04-03 09:15:57 +02:00
2026-06-04 07:41:28 -06:00
2026-04-15 12:34:28 -03:00
2026-05-18 09:47:59 +02:00
2026-04-03 09:15:57 +02:00
2026-04-07 20:34:10 -04:00
2026-06-09 12:18:52 +02:00
2026-05-29 13:36:22 +00:00
2026-06-03 14:57:38 +05:30
2026-05-28 16:19:27 +00:00
2026-06-01 08:02:22 -06:00
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-04-27 17:42:34 +08:00
2026-06-02 11:02:38 -06:00
2026-04-03 09:15:57 +02:00
2026-06-04 11:17:14 +02:00
2026-04-03 09:15:57 +02:00
2026-04-23 18:02:08 +00:00
2026-05-07 16:44:01 -03:00
2026-06-02 09:46:04 -04:00
2026-04-03 09:15:57 +02:00
2026-05-21 07:07:35 -04:00
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-06-09 12:30:13 +02:00
2026-06-02 23:36:14 +10:00
2026-05-04 16:24:44 -07:00
2026-05-08 13:24:25 +08:00
2026-04-27 17:42:34 +08:00
2026-04-03 09:15:57 +02:00
2026-05-25 17:20:56 +02:00
2026-06-05 13:29:43 +02:00
2026-05-18 16:22:12 +07:00
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-04-03 09:15:57 +02:00
2026-05-27 15:19:54 +08:00
2026-04-03 09:15:57 +02:00
2026-04-27 17:42:34 +08:00
2026-06-09 15:49:10 +02:00
2026-04-03 09:15:57 +02:00
2026-05-07 16:44:01 -03:00
2026-05-26 14:02:14 +02:00
2026-05-14 15:12:08 -04:00
2026-05-28 15:22:20 +08:00
2026-06-08 07:32:00 -06:00
2026-05-27 15:19:54 +08:00
2026-04-03 09:15:57 +02:00
2026-06-03 21:07:45 +08:00
2026-04-27 17:42:34 +08:00
2026-05-04 13:08:06 -04:00
2026-05-28 16:19:27 +00:00
2024-07-04 14:48:10 +08:00
2026-01-22 11:17:49 -05:00
2026-03-16 11:22:30 +01:00
2026-04-03 09:15:57 +02:00
2026-04-20 22:32:35 +08:00
2026-04-20 22:32:35 +08:00
2026-04-03 09:15:57 +02:00