Skip to content

Commit 52912b5

Browse files
committed
BF: use get, not casting get_value while dealing with submodule path/url etc
1 parent cf8dc25 commit 52912b5

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

git/objects/submodule/base.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -123,12 +123,12 @@ def _set_cache_(self, attr):
123123
reader = self.config_reader()
124124
# default submodule values
125125
try:
126-
self.path = reader.get_value('path')
126+
self.path = reader.get('path')
127127
except cp.NoSectionError:
128128
raise ValueError("This submodule instance does not exist anymore in '%s' file"
129129
% osp.join(self.repo.working_tree_dir, '.gitmodules'))
130130
# end
131-
self._url = reader.get_value('url')
131+
self._url = reader.get('url')
132132
# git-python extension values - optional
133133
self._branch_path = reader.get_value(self.k_head_option, git.Head.to_full_path(self.k_head_default))
134134
elif attr == '_name':
@@ -1168,11 +1168,11 @@ def iter_items(cls, repo, parent_commit='HEAD'):
11681168

11691169
for sms in parser.sections():
11701170
n = sm_name(sms)
1171-
p = parser.get_value(sms, 'path')
1172-
u = parser.get_value(sms, 'url')
1171+
p = parser.get(sms, 'path')
1172+
u = parser.get(sms, 'url')
11731173
b = cls.k_head_default
11741174
if parser.has_option(sms, cls.k_head_option):
1175-
b = str(parser.get_value(sms, cls.k_head_option))
1175+
b = str(parser.get(sms, cls.k_head_option))
11761176
# END handle optional information
11771177

11781178
# get the binsha

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy