Patchwork D6730: config: handle default values of type list

login
register
mail settings
Submitter phabricator
Date Aug. 16, 2019, 9:08 a.m.
Message ID <46ea8895690f3f0323801d36f02bc693@localhost.localdomain>
Download mbox | patch
Permalink /patch/41309/
State Not Applicable
Headers show

Comments

phabricator - Aug. 16, 2019, 9:08 a.m.
navaneeth.suresh updated this revision to Diff 16219.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D6730?vs=16217&id=16219

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D6730/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D6730

AFFECTED FILES
  mercurial/ui.py

CHANGE DETAILS




To: navaneeth.suresh, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/mercurial/ui.py b/mercurial/ui.py
--- a/mercurial/ui.py
+++ b/mercurial/ui.py
@@ -792,6 +792,8 @@ 
                 itemdefault = item.default()
             else:
                 itemdefault = item.default
+            if isinstance(itemdefault, list):
+                itemdefault = ' '.join(itemdefault)
         return itemdefault
 
     def hasconfig(self, section, name, untrusted=False):