mirror of
https://github.com/n8n-io/n8n.git
synced 2025-03-05 20:50:17 -08:00
fix(editor): Use credentials when fetching node and credential types (#5760)
fix(editor): Use credentials when fetching node and credential types with axios
This commit is contained in:
parent
a732374f24
commit
d3a34ab71b
|
@ -10,7 +10,7 @@ import {
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
|
|
||||||
export async function getCredentialTypes(baseUrl: string): Promise<ICredentialType[]> {
|
export async function getCredentialTypes(baseUrl: string): Promise<ICredentialType[]> {
|
||||||
const { data } = await axios.get(baseUrl + 'types/credentials.json');
|
const { data } = await axios.get(baseUrl + 'types/credentials.json', { withCredentials: true });
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,7 @@ import type {
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
|
|
||||||
export async function getNodeTypes(baseUrl: string) {
|
export async function getNodeTypes(baseUrl: string) {
|
||||||
const { data } = await axios.get(baseUrl + 'types/nodes.json');
|
const { data } = await axios.get(baseUrl + 'types/nodes.json', { withCredentials: true });
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue