Revolyssup commented on code in PR #12465:
URL: https://github.com/apache/apisix/pull/12465#discussion_r2254160326
##########
apisix/plugins/workflow.lua:
##########
@@ -116,10 +120,17 @@ function _M.check_schema(conf)
for idx, rule in ipairs(conf.rules) do
if rule.case then
- local ok, err = expr.new(rule.case)
+ local expr, err = expr.new(rule.case)
if not ok then
return false, "failed to validate the 'case' expression: " ..
err
end
+ local mt = getmetatable(rule)
+ if not mt then
+ mt = {}
+ mt.__index = mt
Review Comment:
mt.__index can only be set after mt is defined.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]