A bit of code duplication going on here. Perhaps this should be:

```ruby
where(@klass.friendly_id_config.query_field => id) or id.friendly_id? ? raise ActiveRecord::RecordNotFound : super
```

Or even:

```ruby
where(@klass.friendly_id_config.query_field => id) or if id.friendly_id?
  raise ActiveRecord::RecordNotFound
else
  super
end
```

The point I'm trying to make is that we should avoid repeating ourselves. :-)