Update state machine

Update to fix an issue preventing the overriding of callback args. It was adding new args instead of overriding the whole args array.