Skip to content

Commit 8ff4b32

Browse files
chore: fix code style in oembed.js (#47)
1 parent 5fccc26 commit 8ff4b32

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/lambda/oembed/oembed.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ function getHostname(event, context) {
1111
return `http://${event.headers.host}`;
1212
}
1313

14-
const netlify = (context.clientContext.custom || {}).netlify;
15-
const decoded = JSON.parse(Buffer.from(netlify, 'base64').toString('utf-8'));
16-
return decoded.site_url;
14+
const { netlify } = context.clientContext.custom || {};
15+
16+
return JSON.parse(Buffer.from(netlify, 'base64').toString('utf-8')).site_url;
1717
}
1818

1919
function handler(event, context, callback) {
@@ -58,7 +58,7 @@ function handler(event, context, callback) {
5858
thumbnail_width: 512,
5959
thumbnail_height: 512,
6060

61-
referrer: referrer,
61+
referrer,
6262
cache_age: 3600,
6363
},
6464
'',

0 commit comments

Comments
 (0)