mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-25 13:29:29 +01:00
Plugin/UrlTitles: add title to "ignored title" log message
This commit is contained in:
parent
bfa08ee8d6
commit
58ac29c4db
@ -202,7 +202,7 @@ sub get_title($self, $context) {
|
||||
my $distance = distance(lc $file, lc $title);
|
||||
my $length = (length $file > length $title) ? length $file : length $title;
|
||||
|
||||
# disregard title if 75%+ similiar to file
|
||||
# disregard title if 75%+ similar to file
|
||||
if ($distance / $length < 0.75) {
|
||||
$self->{pbot}->{logger}->log("URL ($url) is 75% similar to title ($title), disregarding\n");
|
||||
return 0;
|
||||
@ -210,7 +210,7 @@ sub get_title($self, $context) {
|
||||
|
||||
# disregard ignored titles
|
||||
if ($self->is_ignored_title($title)) {
|
||||
$self->{pbot}->{logger}->log("Disregarding ignored title\n");
|
||||
$self->{pbot}->{logger}->log("Disregarding ignored title ($title)\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -25,7 +25,7 @@ use PBot::Imports;
|
||||
# These are set by the /misc/update_version script
|
||||
use constant {
|
||||
BUILD_NAME => "PBot",
|
||||
BUILD_REVISION => 4679,
|
||||
BUILD_REVISION => 4680,
|
||||
BUILD_DATE => "2023-06-13",
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user