From 8056d2849e5fd2cf750c8fdc268222a225ccfaca Mon Sep 17 00:00:00 2001 From: Thomas Wade Date: Sun, 15 May 2022 15:53:08 +0930 Subject: [PATCH] Use relative path for API This allows use behind reverse proxies that modify the path --- scripts/app.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/app.js b/scripts/app.js index 44db350..daf530b 100644 --- a/scripts/app.js +++ b/scripts/app.js @@ -18,7 +18,7 @@ app.controller("mates", ["$scope", "$http", "$interval", function($scope, $http, $scope.lastMate = ""; - $http.get("/mates") + $http.get("mates") .then((r) => { var json = angular.fromJson(r.data); @@ -33,7 +33,7 @@ app.controller("mates", ["$scope", "$http", "$interval", function($scope, $http, // Don't bother updating during a cooldown if ($scope.cooldown) return; - $http.post("/mates") + $http.post("mates") .then((r) => { var json = angular.fromJson(r.data);