Checking API calls
This commit is contained in:
parent
54d4fa50f3
commit
a8f7631ff1
@ -1,6 +1,7 @@
|
||||
import { IsNotEmpty, IsString } from 'class-validator';
|
||||
import { IsNotEmpty, IsNumber, IsString } from 'class-validator';
|
||||
|
||||
export class UpdateAlbumDto {
|
||||
@IsNumber()
|
||||
id: number;
|
||||
|
||||
@IsString()
|
||||
|
@ -58,6 +58,7 @@ export async function createAlbum(formData: FormData) {
|
||||
const title = formData.get('title');
|
||||
const artist = formData.get('artist');
|
||||
const genre = formData.get('genre');
|
||||
console.log(title, artist, genre);
|
||||
return fetch("https://api.anatid.net/album/", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
|
Loading…
x
Reference in New Issue
Block a user