I'm trying to modify `StringVar()` such that the previous data can be remembered

```
class sv(sv):
    def __init__(self):
        self.svm_history = []
        self._name = StringVar()

    def SVM_set(self):
        if self._names:
            if svm_value!=self._name:
                self.svm_history.append(self._name)
                self._name = svm_value

    def SVM_undo(self):    
        return self.svm_history[-2]

```

What am I doing wrong?