mexibot: tighten condition & code cleanup