minor bugfixes in logging

This commit is contained in:
R. Aidan Campbell 2017-10-07 14:14:37 -07:00
parent 7e1dd5d30a
commit 7a6ed6da57

View File

@ -71,8 +71,8 @@ var common = (function() {
* @param {Object} attrs Dictionary of attributes to set on the module. * @param {Object} attrs Dictionary of attributes to set on the module.
*/ */
function createNaClModule(name, tool, path, width, height, attrs) { function createNaClModule(name, tool, path, width, height, attrs) {
console.log('%c[createNaClModule, common.js]', 'color: gray;', "name: " + name, "tool: " + tool, "path: " + path,"width: " + width, console.log('%c[createNaClModule, common.js]', 'color: gray;', "name: " + name + ", tool: " + tool + ", path: " + path + ", width: " + width +
"height: " + height, "attrs: " + attrs); ", height: " + height + ", attrs: " + JSON.stringify(attrs));
var moduleEl = document.createElement('embed'); var moduleEl = document.createElement('embed');
moduleEl.setAttribute('name', 'nacl_module'); moduleEl.setAttribute('name', 'nacl_module');
moduleEl.setAttribute('id', 'nacl_module'); moduleEl.setAttribute('id', 'nacl_module');
@ -91,7 +91,7 @@ var common = (function() {
var mimetype = mimeTypeForTool(tool); var mimetype = mimeTypeForTool(tool);
moduleEl.setAttribute('type', mimetype); moduleEl.setAttribute('type', mimetype);
console.log('%c[createNaClModule, common.js]', 'color: gray;', "moduleEl: " + moduleEl); console.log('%c[createNaClModule, common.js]', 'color: gray;', "moduleEl: " + JSON.stringify(moduleEl));
// The <EMBED> element is wrapped inside a <DIV>, which has both a 'load' // The <EMBED> element is wrapped inside a <DIV>, which has both a 'load'
// and a 'message' event listener attached. This wrapping method is used // and a 'message' event listener attached. This wrapping method is used