fixed bug with latitude and longitude

This commit is contained in:
Alibek 2024-03-18 16:33:57 +06:00
parent 006a1a7b7b
commit c54131197e
5 changed files with 6 additions and 19 deletions

View File

@ -5,7 +5,7 @@
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start -p 8004",
"start": "next start -p 3000",
"lint": "next lint"
},
"dependencies": {

View File

@ -11,7 +11,6 @@ import React from "react";
const Personal = async () => {
const session = await getServerSession(authConfig);
console.log(session?.expires_in);
const getProfile = async () => {
const Authorization = `Bearer ${session?.access_token}`;
const config = {

View File

@ -6,18 +6,6 @@ import { apiInstance } from "./apiConfig";
import { IRefresh, ITokens } from "../types/token-type";
import GoogleProvider from "next-auth/providers/google";
const verifyToken = async (access_token: string) => {
const res = await apiInstance.post("/token/verify/", {
token: access_token,
});
if ([200, 201].includes(res.status)) {
return true;
}
return false;
};
const refreshToken = async (token: JWT): Promise<JWT> => {
const UTC = new Date();

View File

@ -110,10 +110,10 @@ const ReportForm = () => {
});
formData.append("latitude1", latLng[0].lat.toString());
formData.append("longitude1", latLng[0].lng.toString());
// if (latLng.length === 2) {
formData.append("latitude2", latLng[1].lat.toString());
formData.append("longitude2", latLng[1].lng.toString());
// }
if (latLng.length === 2) {
formData.append("latitude2", latLng[1].lat.toString());
formData.append("longitude2", latLng[1].lng.toString());
}
try {
setLoader(true);

View File

@ -79,7 +79,7 @@
a {
display: flex;
font-size: 20px;
color: rgb(50, 48, 58);
color: rgb(72, 159, 225);
}
}