Skip to content

Commit 639efef

Browse files
committed
Fix a bug of sentry
1 parent 0ec4e5f commit 639efef

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

app/views/layouts/application.html.erb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@
3131
environment: '<%= Rails.env %>',
3232
release: '<%= ENV['BUILD_HASH'] %>'
3333
});
34-
Sentry.setUser({ id: <%= current_user&.id.to_json %> });
34+
Sentry.configureScope(function (scope) {
35+
scope.setUser({ id: <%= current_user&.id.to_json %> });
36+
});
3537
</script>
3638
<% end %>
3739

0 commit comments

Comments
 (0)