diff --git a/lyrebird/mock/handlers/handler_context.py b/lyrebird/mock/handlers/handler_context.py index d007d3632..591dd4f5d 100644 --- a/lyrebird/mock/handlers/handler_context.py +++ b/lyrebird/mock/handlers/handler_context.py @@ -189,6 +189,9 @@ def get_request_body(self, in_request_handler=True): else: if in_request_handler: _data = self.request.data or self.request.form or None + # When origin_request is not saved, the original data cannot be obtained when diff-mode is enabled. + elif self.flow.get('origin_request', {}).get('data'): + _data = self.flow.get('origin_request', {}).get('data') else: _data = DataHelper.flow2origin(self.flow['request']) return _data diff --git a/lyrebird/version.py b/lyrebird/version.py index 74bd5144d..a87433bee 100644 --- a/lyrebird/version.py +++ b/lyrebird/version.py @@ -1,3 +1,3 @@ -IVERSION = (2, 21, 0) +IVERSION = (2, 21, 1) VERSION = ".".join(str(i) for i in IVERSION) LYREBIRD = "Lyrebird " + VERSION