diff --git a/README.md b/README.md index 7cd2e05..5eb46d1 100644 --- a/README.md +++ b/README.md @@ -168,7 +168,9 @@ Explore the files in `src/config` to modify pairing and relay server configurati ### Troubleshooting -If you run into any issues with a custom Chitchatter installation, first ensure that you are using [the latest version of the code](https://github.com/jeremyckahn/chitchatter/tree/main). +If you run into any issues with a custom Chitchatter installation, first ensure that you are using [the latest version of the code](https://github.com/jeremyckahn/chitchatter/tree/main). If you are hosting your installation with GitHub Pages, sync your `main` branch and _not_ your `gh-pages` branch. Updating your `main` branch will trigger a proper rebuild of your `gh-pages` branch. + +- https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork #### Peers won't connect diff --git a/public/404.html b/public/404.html index e8bdb81..48f96fb 100644 --- a/public/404.html +++ b/public/404.html @@ -24,7 +24,10 @@ // https://username.github.io/repo-name/one/two?a=b&c=d#qwe becomes // https://username.github.io/repo-name/?/one/two&a=b~and~c=d#qwe // Otherwise, leave pathSegmentsToKeep as 0. - var pathSegmentsToKeep = 0 + //var pathSegmentsToKeep = 0 + var pathSegmentsToKeep = window.location.origin.endsWith('.github.io') + ? 1 + : 0 var l = window.location l.replace(