Skip to content

Conversation

@HashidaTKS
Copy link
Contributor

Add feature to automatically close ERR_CACHE_MISS page like below.

image

if (this.match(section, urlToMatch)) {
console.log(` => unmatched`);
this.startMonitoring();
callbackWhenMatch();
Copy link
Contributor Author

@HashidaTKS HashidaTKS Aug 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

今回の機能追加で、このメソッドを流用したい。ただ、今回追加した部分と従来の部分でマッチした場合にさせたい動作が異なる。

  • ERR_CACHE_MISSページのURLが合致していた場合はタブを閉じたい。
  • それ以外の場合は、RepostConfirmationCanceler.exeを起動したい。

マッチ時にさせたい動作が異なるので、コールバック化して外部から渡せるようにした。

* }
*/
const RepostConfirmationCancelerTalkClient = {
const RepostConfirmationCanceler = {
Copy link
Contributor Author

@HashidaTKS HashidaTKS Aug 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

このオブジェクトの中にERR_CACHE_MISSのページだったらタブを閉じる、という処理を追加した。
そのため単なるTalkClientではなくなったのでリネームした。

Copy link
Member

@piroor piroor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@piroor piroor merged commit 8af267c into main Aug 13, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants