Fix button serialization

/cc @dgraham