Fixed sexp refactoring behaviour