forked from mirrors/misskey
refactor
This commit is contained in:
@@ -68,6 +68,11 @@ function send() {
|
|||||||
|
|
||||||
function onEndpointChange() {
|
function onEndpointChange() {
|
||||||
misskeyApi('endpoint', { endpoint: endpoint.value }, withCredential.value ? undefined : null).then(resp => {
|
misskeyApi('endpoint', { endpoint: endpoint.value }, withCredential.value ? undefined : null).then(resp => {
|
||||||
|
if (resp == null) {
|
||||||
|
body.value = '{}';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const endpointBody = {};
|
const endpointBody = {};
|
||||||
for (const p of resp.params) {
|
for (const p of resp.params) {
|
||||||
endpointBody[p.name] =
|
endpointBody[p.name] =
|
||||||
|
|||||||
Reference in New Issue
Block a user