Skip to content

Commit

Permalink
fix failing script errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ccorda committed Dec 30, 2022
1 parent 9494d00 commit 90f509b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
2 changes: 1 addition & 1 deletion wp-content/themes/timber/assets/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ var widont = function () {
$element.html(
$(this)
.html()
.replace(/\s([^\s<]{0,8})\s*$/, '&nbsp;$1'),
.replace(/\s([^\s<]{0,8})\s*$/, '&nbsp;$1')
);
});
};
Expand Down
13 changes: 5 additions & 8 deletions wp-content/themes/timber/views/layout.twig
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
ga( 'require', 'outboundLinkTracker' );{% if environment == "development" or user %}
// No GA data sent while in dev or logged in
ga( 'set', 'sendHitTask', null );{% endif %}
ga( 'send', 'pageview' );
ga( 'set', 'sendHitTask', null );{% endif %}ga( 'send', 'pageview' );
</script>

<script src='https://www.google-analytics.com/analytics.js'></script>
Expand Down Expand Up @@ -100,10 +98,10 @@
{% endif %}

{#
- Load JS libs then custom scripts. Paths should be relative to assets folder
- Build block uses gulp-useref to copy/rev assets
- Rev function uses a custom php helper that adjusts filesname depending on env, and adds md5 hash in production
#}
- Load JS libs then custom scripts. Paths should be relative to assets folder
- Build block uses gulp-useref to copy/rev assets
- Rev function uses a custom php helper that adjusts filesname depending on env, and adds md5 hash in production
#}

{% set rev_js %}
<!-- build:js js/all.js -->
Expand All @@ -113,7 +111,6 @@
<script src="vendor/bootstrap/dist/js/bootstrap.bundle.js"></script>
<script src="vendor/jquery-match-height/jquery.matchHeight.js"></script>
<script src="js/console-safe.js"></script>
<script src="js/analytics-sourcing.js"></script>
<script src="js/main.js"></script>
<!-- endbuild -->
{% endset %}
Expand Down

0 comments on commit 90f509b

Please sign in to comment.