Skip to content

Commit

Permalink
Allow offline usage for POIs #1169 - Revert logging in master
Browse files Browse the repository at this point in the history
  • Loading branch information
HarelM committed Jun 7, 2020
1 parent a2ebcc2 commit 815981b
Showing 1 changed file with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,15 @@ import { encode } from "base64-arraybuffer";

import { RunningContextService } from "../services/running-context.service";
import { DatabaseService } from "../services/database.service";
import { LoggingService } from "../services/logging.service";

@Pipe({ name: "offlineImage" })
export class OfflineImagePipe implements PipeTransform {
constructor(private readonly http: HttpClient,
private readonly runningContextService: RunningContextService,
private readonly loggingService: LoggingService,
private readonly databaseService: DatabaseService) {
}

public async transform(value: string, cache: boolean): Promise<string> {
// HM TODO: remove this when issue is resolved!
this.loggingService.debug("Showing image: " + value + ", isOnline: " + this.runningContextService.isOnline + ", cache: " + cache);
if (!this.runningContextService.isOnline) {
let data = await this.databaseService.getImageByUrl(value);
if (data != null) {
Expand Down

0 comments on commit 815981b

Please sign in to comment.