Display the API keys
This commit is contained in:
parent
933a4733e8
commit
3ef649d984
2 changed files with 42 additions and 3 deletions
|
@ -19,7 +19,7 @@ export const rawDataToApiKey = (data: any): ApiKey => ({
|
|||
export default (): Promise<ApiKey[]> => {
|
||||
return new Promise((resolve, reject) => {
|
||||
http.get('/api/client/account/api-keys')
|
||||
.then(({ data }) => resolve((data.data || []).map(rawDataToApiKey)))
|
||||
.then(({ data }) => resolve((data.data || []).map((d: any) => rawDataToApiKey(d.attributes))))
|
||||
.catch(reject);
|
||||
});
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue