mirror of
https://github.com/yawaflua/LuckyDiamond.git
synced 2025-12-10 12:19:31 +02:00
Add stable version of double
This commit is contained in:
22
luckydiamond/src/assets/js/games/double/DoubleApi.js
Normal file
22
luckydiamond/src/assets/js/games/double/DoubleApi.js
Normal file
@@ -0,0 +1,22 @@
|
||||
import { BackendApiUrl } from '@/properties/Сonfig.js';
|
||||
|
||||
export async function GetNewestDoubleGames() {
|
||||
try {
|
||||
const response = await fetch(`${BackendApiUrl}/GameDouble/GetNewestDoubleGames`, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
redirect: 'follow'
|
||||
})
|
||||
|
||||
if (!response.ok) {
|
||||
console.log('Fetch error:', response.status)
|
||||
}
|
||||
|
||||
return await response
|
||||
}
|
||||
catch (error) {
|
||||
console.log('Fetch error')
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user