Fix behavior issue

This commit is contained in:
ElCeejo 2022-05-31 14:07:50 -07:00 committed by GitHub
parent 8379af33f5
commit 5846ab1cb9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1155,13 +1155,16 @@ function mob:_execute_utilities()
end end
end end
if loop_data.utility if loop_data.utility
and loop_data.args and loop_data.args then
and self._utility_data.args then if not self._utility_data then
local no_data = not self._utility_data.utility and not self._utility_data.args
local new_util = self._utility_data.utility ~= loop_data.utility or not tbl_equals(self._utility_data.args, loop_data.args)
if no_data
or new_util then -- if utilities are different or utilities are the same and args are different set new data
self._utility_data = loop_data self._utility_data = loop_data
else
local no_data = not self._utility_data.utility and not self._utility_data.args
local new_util = self._utility_data.utility ~= loop_data.utility or not tbl_equals(self._utility_data.args, loop_data.args)
if no_data
or new_util then -- if utilities are different or utilities are the same and args are different set new data
self._utility_data = loop_data
end
end end
end end
if self._utility_data.utility then if self._utility_data.utility then