Commits

Ali Gholami Rudi  committed 28fc79b

added default parameter to get()

  • Participants
  • Parent commits 1ea1f12

Comments (0)

Files changed (1)

File ropemacs/__init__.py

     def y_or_n(self, prompt):
         return lisp.y_or_n_p(prompt)
 
-    def get(self, name):
+    def get(self, name, default=None):
         lispname = 'ropemacs-' + name.replace('_', '-')
         if lisp.boundp(lisp[lispname]):
             return lisp[lispname].value()
+        return default
 
     def get_offset(self):
         return lisp.point() - 1