mirror of
https://github.com/go-gitea/gitea.git
synced 2024-12-15 17:49:20 +08:00
6d96f0b0d1
1. Introduce lightweight `fetch` wrapper functions that automatically sets csfr token, content-type and use it in `RepoActionView.vue`. 2. Fix a specific issue on `RepoActionView.vue` where a fetch network error is shortly visible during page reload sometimes. It can be reproduced by F5-in in quick succession on the actions view page and was also producing a red error box on the page. Once approved, we can replace all current `fetch` uses in UI with this in another PR. --------- Co-authored-by: Giteabot <teabot@gitea.io>
12 lines
336 B
JavaScript
12 lines
336 B
JavaScript
import {test, expect} from 'vitest';
|
|
import {GET, POST, PATCH, PUT, DELETE} from './fetch.js';
|
|
|
|
// tests here are only to satisfy the linter for unused functions
|
|
test('exports', () => {
|
|
expect(GET).toBeTruthy();
|
|
expect(POST).toBeTruthy();
|
|
expect(PATCH).toBeTruthy();
|
|
expect(PUT).toBeTruthy();
|
|
expect(DELETE).toBeTruthy();
|
|
});
|