activity log returns nil on errors from methods which call an association
| 27 | 28 | |
|---|---|---|
| 11 | 11 | "You must set a :method in the options to use this") : |
| 12 | 12 | the_culprit |
| 13 | 13 | rescue |
| 14 | return "anonymous" | |
| 14 | return nil | |
| 15 | 15 | end |
| 16 | 16 | |
| 17 | 17 | alias the_referenced referenced |
| --- | --- | |
| 22 | 22 | "You must set a :method in the options to use this") : |
| 23 | 23 | the_referenced |
| 24 | 24 | rescue |
| 25 | return "anonymous" | |
| 25 | return nil | |
| 26 | 26 | end |
| 27 | 27 | |
| 28 | 28 | alias the_activity_loggable activity_loggable |
| --- | --- | |
| 33 | 33 | "You must set a :method in the options to use this") : |
| 34 | 34 | the_activity_loggable |
| 35 | 35 | rescue |
| 36 | return "anonymous" | |
| 36 | return nil | |
| 37 | 37 | end |
| 38 | 38 | |
| 39 | 39 | def self.latest(limit=5) |
