README.md in safely_block-0.1.1 vs README.md in safely_block-0.2.0
- old
+ new
@@ -55,11 +55,13 @@
```
Silence exceptions
```ruby
-safely(silence: ActiveRecord::RecordNotUnique) { code }
+safely silence: ActiveRecord::RecordNotUnique do
+ # code
+end
```
Throttle reporting with:
```ruby
@@ -72,23 +74,23 @@
## Reporting
Reports exceptions to a variety of services out of the box thanks to [Errbase](https://github.com/ankane/errbase).
-- [Rollbar](https://rollbar.com/)
- [Airbrake](https://airbrake.io/)
+- [Appsignal](https://appsignal.com/)
+- [Bugsnag](https://bugsnag.com/)
- [Exceptional](http://www.exceptional.io/)
- [Honeybadger](https://www.honeybadger.io/)
-- [Sentry](https://getsentry.com/)
-- [Raygun](https://raygun.io/)
-- [Bugsnag](https://bugsnag.com/)
-- [Appsignal](https://appsignal.com/)
- [Opbeat](https://opbeat.com/)
+- [Raygun](https://raygun.io/)
+- [Rollbar](https://rollbar.com/)
+- [Sentry](https://getsentry.com/)
Customize reporting with:
```ruby
-Safely.report_exception_method = proc { |e| Rollbar.error(e) }
+Safely.report_exception_method = -> (e) { Rollbar.error(e) }
```
By default, exception messages are prefixed with `[safely]`. This makes it easier to spot rescued exceptions. Turn this off with:
```ruby