Eero Kaukonen [Atlassian]  committed 25b43ab Merge

Merged in feature/AC-1119-template-for-unauthorized (pull request #8)

AC-1119: a simple template for expired tokens

  • Participants
  • Parent commits 6fb9631, c7cd813

Comments (0)

Files changed (2)

     // This is the port your Express server will listen on
     "port": 3000,
+    //Use 'unauthorized.hbs' template for displaying an error page
+    "errorTemplate": true,
     // alassian-connect-express currently integrates with JugglingDB for persistence
     // to store the host client information (i.e., client key, host public
     // key, etc). When no adapter is specified, it defaults to JugglingDB's
     // HTTP port to you via the PORT environement variable, so we configure
     // that to be honored here.
     "port": "$PORT",
+    //Use 'unauthorized.hbs' template for displaying an error page
+    "errorTemplate": true,
     // This is the public URL to your production add-on.
     "localBaseUrl": "",
     "store": {

File views/unauthorized.hbs

+<!doctype html>
+  <meta charset="utf-8">
+  <meta http-equiv="X-UA-Compatible" content="IE=edge">
+  <meta http-equiv="cache-control" content="no-cache" />
+  <meta name="ap-local-base-url" content="{{localBaseUrl}}">
+  <title>{{title}}</title>
+  <script src="{{hostScriptUrl}}" type="text/javascript"></script>
+  <link rel="stylesheet" href="//" media="all">
+  <link rel="stylesheet" href="//" media="all">
+  <!--[if IE 9]><link rel="stylesheet" href="//" media="all"><![endif]-->
+<p>Unauthorized: {{message}}</p>