Feature(offline): don't attempt to upload images if offline

This commit is contained in:
Pieter Vander Vennet 2025-08-05 23:55:10 +02:00
parent 7155cd7f61
commit f1da97285f

View file

@ -16,6 +16,7 @@ import OsmObjectDownloader from "../Osm/OsmObjectDownloader"
import ExifReader from "exifreader"
import { Utils } from "../../Utils"
import { Lists } from "../../Utils/Lists"
import { IsOnline } from "../Web/IsOnline"
/**
* The ImageUploadManager has a
@ -172,6 +173,9 @@ export class ImageUploadManager {
if (this.uploadingAll) {
return
}
if(!IsOnline.isOnline){
return
}
try {
let queue: ImageUploadArguments[]
const failed: Set<ImageUploadArguments> = new Set()