Commits

Yuya Nishihara committed 7270e8c

commit: remove unneeded arguments from getBranchCommandLine()

- branchName is unused
- repo is self.repo

  • Participants
  • Parent commits 3659d1c

Comments (0)

Files changed (1)

File tortoisehg/hgqt/commit.py

         self.committb.setText(curraction._text)
         self.lastAction = curraction._name
 
-    def getBranchCommandLine(self, branchName, repo):
+    def getBranchCommandLine(self):
         '''
         Create the command line to change or create the selected branch unless
         it is the selected branch
         the selected action
         '''
         # This function is used both by commit() and mqPerformAction()
+        repo = self.repo
         commandlines = []
         newbranch = False
         branch = hglib.fromunicode(self.branchop)
         # Check if we need to change branch first
         wholecmdlines = []  # [[cmd1, ...], [cmd2, ...], ...]
         if self.branchop:
-            cmdlines, newbranch = self.getBranchCommandLine(self.branchop,
-                                                            self.repo)
+            cmdlines, newbranch = self.getBranchCommandLine()
             if cmdlines is None:
                 return
             wholecmdlines.extend(cmdlines)
         elif self.branchop == False:
             brcmd = ['--close-branch']
         else:
-            commandlines, newbranch = self.getBranchCommandLine(self.branchop,
-                                                                self.repo)
+            commandlines, newbranch = self.getBranchCommandLine()
             if commandlines is None:
                 return
         partials = []