Skip to content

Commit

Permalink
fix: 恢复is_frozen方法try修改 TencentBlueKing#1469
Browse files Browse the repository at this point in the history
  • Loading branch information
huangpixu committed Feb 11, 2025
1 parent f64adcd commit 181d091
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions pipeline/engine/models/function.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,7 @@ def init_db(self):
logger.error("function switch init failed: %s" % traceback.format_exc())

def is_frozen(self):
try:
is_frozen = self.get(name=function_switch.FREEZE_ENGINE).is_active
except FunctionSwitch.DoesNotExist:
is_frozen = None
return is_frozen
return self.get(name=function_switch.FREEZE_ENGINE).is_active

def freeze_engine(self):
self.filter(name=function_switch.FREEZE_ENGINE).update(is_active=True)
Expand Down

0 comments on commit 181d091

Please sign in to comment.