You could change this line to:

```ruby
Array(key)
```