Fix building $options array