Fix logic to generate asset_url even if the asset_id is provided so

an error is avoided
This commit is contained in:
Jeff Nelson
2017-12-13 07:38:10 -06:00
parent 27ecbd1bdd
commit df925f5a1a
+2 -3
View File
@@ -70,10 +70,9 @@ export class Talk {
// Extract the asset url.
if (opts.asset_url) {
query.asset_url = opts.asset_url;
} else if (!opts.asset_id) {
} else {
// The asset url was not provided and the asset id was also not provided,
// we need to infer the asset url from details on the page.
// The asset url was not provided so we need to infer the asset url from // details on the page.
try {
query.asset_url = document.querySelector('link[rel="canonical"]').href;