small mex cleanups