Skip to content

Commit

Permalink
Simplified code
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisn committed Feb 5, 2024
1 parent bedd620 commit 1c30821
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -343,13 +343,10 @@ Peaks.init = function(opts, callback) {

let err = instance._setOptions(opts);

if (err) {
callback(err);
return;
if (!err) {
err = checkContainerElements(instance.options);
}

err = checkContainerElements(instance.options);

if (err) {
callback(err);
return;
Expand Down

0 comments on commit 1c30821

Please sign in to comment.