From 1546e77e9b2796f20215caa23f06822c96be27ee Mon Sep 17 00:00:00 2001 From: gebele Date: Mon, 5 Aug 2019 09:48:54 +0000 Subject: ensure xhr requests are https to avoid mixed content issue in browsers --- lib/model.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/model.rb') diff --git a/lib/model.rb b/lib/model.rb index b26447d..55172b0 100644 --- a/lib/model.rb +++ b/lib/model.rb @@ -145,7 +145,7 @@ post "/api/model/:id/?" do @task.save end#main task tid = @task.id.to_s - return 202, to("/task/#{tid}").to_json + return 202, "//#{ENV['VIRTUAL_HOST']}/task/#{tid}".to_json else halt 400, "No accepted content type" end -- cgit v1.2.3