Fix inverted mode