Skip to content

Commit ac72fc7

Browse files
More elegant URL for iframe
1 parent 335ba55 commit ac72fc7

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

index.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -114,13 +114,7 @@ app.get('/', function(req, res){
114114
});
115115

116116
app.get('/analytics', restrict, function(req, res){
117-
var iframeUrl = url.format({
118-
pathname: `${METABASE_SITE_URL}/auth/sso`,
119-
query: {
120-
jwt: signUserToken(req.session.user),
121-
return_to: "/dashboard/2-a-look-at-your-invoices-table"
122-
}
123-
})
117+
var iframeUrl = '/sso/metabase?return_to=/dashboard/2-a-look-at-your-invoices-table';
124118
res.send(`<iframe src="${iframeUrl}" frameborder="0" width="1280" height="600" allowtransparency></iframe>`);
125119
});
126120

0 commit comments

Comments
 (0)