Edit ´getAttributeValue´ to a function declaration

Favoring function declaration over a function expression in this case to follow style guidelines.
This commit is contained in:
Vitor Cortez 2015-10-02 20:46:02 -03:00 committed by Zeno Rocha
parent ff4755fe4c
commit 15a66df290

View File

@ -9,7 +9,7 @@ const prefix = 'data-clipboard-';
* @param {String} suffix * @param {String} suffix
* @param {Element} element * @param {Element} element
*/ */
var getAttributeValue = (suffix, element) => { function getAttributeValue(suffix, element) {
let attribute = prefix + suffix; let attribute = prefix + suffix;
if (!element.hasAttribute(attribute)) { if (!element.hasAttribute(attribute)) {
@ -17,7 +17,7 @@ var getAttributeValue = (suffix, element) => {
} }
return element.getAttribute(attribute); return element.getAttribute(attribute);
}; }
/** /**
* Base class which takes a selector, delegates a click event to it, * Base class which takes a selector, delegates a click event to it,