I usually find this more readable, also allows to extend states in the future,
```ruby
result = case history['result']
                  when HISTORY_ERROR
                       ERROR
                  when HISTORY_SUCCESS
                       FINISHED
                  else
                       history['result']
                   end
```