Skip to content

Commit 2f48df2

Browse files
HypnosphiAlexanderPrendota
authored andcommitted
fix: exception in non-browser environments (#61)
1 parent 8d33fe3 commit 2f48df2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ export function dashToCamel(string) {
5656
* @return {Object<string, string>}
5757
*/
5858
export function getConfigFromElement(element, mergeWithDefaults = false) {
59-
if (!element.attributes) {
59+
if (!element || !element.attributes) {
6060
return {};
6161
}
6262

0 commit comments

Comments
 (0)