Skip to content

Commit

Permalink
Merge pull request #664 from Peergos/feat/signup-at-peergosdotnet
Browse files Browse the repository at this point in the history
If a server is not accepting signups and is localhost,
  • Loading branch information
ianopolous authored Jan 30, 2025
2 parents 0879a6b + 2640f18 commit e2cda81
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/components/Signup.vue
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,12 @@
</div>
</div>
</template>

<template v-else-if="showSignupWarning">
<h2>This server is currently not accepting signups</h2>
<strong>Please sign up here first: <br/>
<a class="line" href="https://peergos.net?signup=true">https://peergos.net?signup=true</a>.</strong>
</template>

<template v-else>
<h2>This server is currently not accepting signups</h2>
Expand Down Expand Up @@ -159,6 +165,7 @@ module.exports = {
continue_body: "Continue to our payment processor to enter your card details",
continue_func: function(){},
cardFuture: null,
showSignupWarning: false,
};
},
Expand All @@ -178,6 +185,8 @@ module.exports = {
if (that.token.length > 0) return;
that.acceptingFreeSignups = res.free;
that.acceptingPaidSignups = res.paid;
if (!res.free && window.location.hostname == "localhost")
that.showSignupWarning = true;
console.log("accepting signups - free: " + res.free + ", paid: " + res.paid);
});
},
Expand Down

0 comments on commit e2cda81

Please sign in to comment.