• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

allura


Commit MetaInfo

修订版7941b68485b3f2d6fcc037a46d6889bf5d4f3cd9 (tree)
时间2011-11-11 03:47:14
作者Rick Copeland <rcopeland@geek...>
CommiterJohn Hoffmann

Log Message

[#2718] Make project.get_tool_data take a default argument that does something

Signed-off-by: Rick Copeland <rcopeland@geek.net>

更改概述

差异

--- a/Allura/allura/model/project.py
+++ b/Allura/allura/model/project.py
@@ -183,7 +183,7 @@ class Project(MappedClass):
183183 return TroveCategory.query.find({'_id':{'$in':getattr(self,'trove_%s' % trove_type)}}).all()
184184
185185 def get_tool_data(self, tool, key, default=None):
186- return self.tool_data.get(tool, {}).get(key, None)
186+ return self.tool_data.get(tool, {}).get(key, default)
187187
188188 def set_tool_data(self, tool, **kw):
189189 d = self.tool_data.setdefault(tool, {})