def callback_with_history(callback, cmd_history, input_text):
    if callback:
        cmd = input_text.split("\n")[active_input_row]
        if cmd_history in cmd:
            cmd_history.remove(cmd)
        cmd_history.append(cmd)
        return callback(cmd)
dataset/ETHPy150Open misfo/Shell-Turtlestein/shell_turtlestein.py/callback_with_history/swapped operands of `in`