diff options
| author | Maria Lisina <sekoohaka.sarisan@gmail.com> | 2025-05-22 16:17:41 +0500 |
|---|---|---|
| committer | Maria Lisina <sekoohaka.sarisan@gmail.com> | 2025-05-22 16:17:41 +0500 |
| commit | 57d2eb6472530dc52186c3b2f2cc128ede3d118f (patch) | |
| tree | c7a2a733d046c5995ec3d23a4091989b99b4351f | |
| parent | 71fabcb56800205b55e8a658edfb29b5052ff461 (diff) | |
bot: Fix cache overlapping properlyv4.0-pre6
Signed-off-by: Maria Lisina <sekoohaka.sarisan@gmail.com>
| -rw-r--r-- | submodules/inline_search_posts.zsh | 9 | ||||
| -rw-r--r-- | submodules/url_parser.zsh | 2 | ||||
| -rw-r--r-- | units/ib_common.zsh | 5 | ||||
| -rw-r--r-- | units/ib_hash.zsh | 2 |
4 files changed, 12 insertions, 6 deletions
diff --git a/submodules/inline_search_posts.zsh b/submodules/inline_search_posts.zsh index a0bfdca..4dd6790 100644 --- a/submodules/inline_search_posts.zsh +++ b/submodules/inline_search_posts.zsh @@ -128,6 +128,13 @@ fi if [[ "${caching_mode}" = "advanced" ]] then - ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_id}" | enhash)" + if [[ "${ib_name}" = "Idol Complex" ]] + then + ib_query="md5:${ib_md5}" + else + ib_query="id:${ib_id}" + fi + + ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_query}" | enhash)" . "${units}/ib_cache.zsh" & fi diff --git a/submodules/url_parser.zsh b/submodules/url_parser.zsh index 501febf..5c2c272 100644 --- a/submodules/url_parser.zsh +++ b/submodules/url_parser.zsh @@ -59,7 +59,7 @@ else ib_query="id:${ib_post_id}" fi -ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_post_id}" | enhash)" +ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_query}" | enhash)" . "${units}/ib_file.zsh" if [[ -n "${output_text}" ]] diff --git a/units/ib_common.zsh b/units/ib_common.zsh index 1e8a639..a2ddfd5 100644 --- a/units/ib_common.zsh +++ b/units/ib_common.zsh @@ -45,8 +45,7 @@ fi if [[ -n "${ib_parent}" ]] then - ib_post_id="${ib_post_id} -id:${ib_post_id}" - ib_query="parent:${ib_post_id}" + ib_query="parent:${ib_post_id} -id:${ib_post_id}" elif [[ ${#ib_post_id} -eq 32 ]] then ib_query="md5:${ib_post_id}" @@ -57,5 +56,5 @@ else ib_query="id:${ib_post_id}" fi -ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_post_id}" | enhash)" +ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_query}" | enhash)" . "${units}/ib_file.zsh" diff --git a/units/ib_hash.zsh b/units/ib_hash.zsh index f579180..cc90bf4 100644 --- a/units/ib_hash.zsh +++ b/units/ib_hash.zsh @@ -9,7 +9,7 @@ ib_mode="p" ib_query="md5:${ib_post_md5}" -ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_post_md5}" | enhash)" +ib_hash="$(printf "%s%s%s" "${user_id}" "${ib_board}" "${ib_query}" | enhash)" . "${units}/ib_file.zsh" if [[ -z "${output_text}" ]] |
