Fixed small mapping errors with munge and flip functions.