Added rate limiting logging and an error page for hitting the rate limit on opening characters
This commit is contained in:
17
rpg-docs/client/views/meta/error/error.js
Normal file
17
rpg-docs/client/views/meta/error/error.js
Normal file
@@ -0,0 +1,17 @@
|
||||
Template.error.onRendered(function(){
|
||||
const error = Session.get("error") || {};
|
||||
if (error.href) window.history.replaceState("", "", error.href);
|
||||
});
|
||||
|
||||
Template.error.helpers({
|
||||
errorMessage: function(){
|
||||
const error = Session.get("error") || {};
|
||||
return error.reason;
|
||||
},
|
||||
});
|
||||
|
||||
Template.error.events({
|
||||
"click .try-again": function(event, instance){
|
||||
window.location.reload();
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user