You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "monkeyDluffy6017 (via GitHub)" <gi...@apache.org> on 2023/03/22 15:37:39 UTC
[GitHub] [apisix] monkeyDluffy6017 commented on a diff in pull request #8358: refactor: refactor get last index func in log rotate plugin
monkeyDluffy6017 commented on code in PR #8358:
URL: https://github.com/apache/apisix/pull/8358#discussion_r1145015398
##########
apisix/core/utils.lua:
##########
@@ -335,4 +337,19 @@ end
_M.resolve_var = resolve_var
+function _M.get_last_index(str, key)
+ local str_rev = str_reverse(str)
+ local key_rev = str_reverse(key)
+ local idx, _ = str_find(str_rev, key_rev)
Review Comment:
Done
--
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: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org