Skip to content

Commit

Permalink
libcurl --> epoxy
Browse files Browse the repository at this point in the history
  • Loading branch information
derpbyte committed Aug 20, 2024
1 parent ba53f9d commit 2db9f14
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import express from 'express';
import http from 'node:http';
import path from 'node:path';
import { libcurlPath } from "@mercuryworkshop/libcurl-transport";
import { epoxyPath } from "@mercuryworkshop/epoxy-transport";
import { baremuxPath } from "@mercuryworkshop/bare-mux/node";
import wisp from "wisp-server-node";
import request from '@cypress/request';
Expand All @@ -21,7 +21,7 @@ app.use(
})
);

app.use("/libcurl/", express.static(libcurlPath));
app.use("/epoxy/", express.static(epoxyPath));
app.use("/baremux/", express.static(baremuxPath));
app.use(express.static(path.join(__dirname, 'static')));

Expand Down Expand Up @@ -103,5 +103,5 @@ process.on('SIGTERM', () => shutdown('SIGTERM'));
process.on('SIGINT', () => shutdown('SIGINT'));

server.listen({
port: 8000,
port: 8001,
});
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"dependencies": {
"@cypress/request": "^3.0.0",
"@mercuryworkshop/bare-mux": "^2.0.4",
"@mercuryworkshop/libcurl-transport": "^1.3.7",
"@mercuryworkshop/epoxy-transport": "^2.1.5",
"wisp-server-node": "^1.1.3",
"chalk": "^5.3.0",
"express": "^4.18.2"
Expand Down
2 changes: 1 addition & 1 deletion static/assets/js/loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ function decode(url) {
if (url === 'about:blank' || url === 'welcome.html') {
return ''
}
else if (url === 'welcome.html' || url === 'https://beta.derpman.lol/welcome.html') {
else if (url === 'welcome.html' || url === 'https://' + location.hostname + '/welcome.html') {
return ''
}
var uvPrefix = '/service/';
Expand Down
2 changes: 1 addition & 1 deletion static/assets/js/preload.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ window.onload = function() {
if(location.protocol !== "https:" && !swAllowedHostnames.includes(location.hostname)) throw new Error("Service workers cannot be registered without https.");
throw new Error("Your browser doesn't support service workers.");
}
await connection.setTransport("/libcurl/index.mjs", [{
await connection.setTransport("/epoxy/index.mjs", [{
wisp: wispUrl
}]);
await navigator.serviceWorker.register(stockSW);
Expand Down
2 changes: 1 addition & 1 deletion static/assets/js/register.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ async function registerSW() {
throw new Error("Your browser doesn't support service workers.");
}

await connection.setTransport("/libcurl/index.mjs", [{ wisp: wispUrl }]);
await connection.setTransport("/epoxy/index.mjs", [{ wisp: wispUrl }]);
await navigator.serviceWorker.register(stockSW);

}
Expand Down

0 comments on commit 2db9f14

Please sign in to comment.