X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=lib%2FPublicInbox%2FMsgTime.pm;h=5ee087fd50fea18612798d094046b4ada12d16e1;hb=af0b0fb7a454470a32c452119d0392e0dedb3fe1;hp=bd7ef8117d30fb5ad32aeef4f46c1813edd06fbd;hpb=8e81d6f0d44198717ae540421a09824d75c9bb6d;p=public-inbox.git
diff --git a/lib/PublicInbox/MsgTime.pm b/lib/PublicInbox/MsgTime.pm
index bd7ef811..5ee087fd 100644
--- a/lib/PublicInbox/MsgTime.pm
+++ b/lib/PublicInbox/MsgTime.pm
@@ -1,4 +1,4 @@
-# Copyright (C) 2018-2020 all contributors
+# Copyright (C) 2018-2021 all contributors
# License: AGPL-3.0+
# Various date/time-related functions
@@ -95,7 +95,7 @@ sub str2date_zone ($) {
$sign = '+' if $off == 0;
$zone = sprintf('%s%02d%02d', $sign, $tz_hh, $tz_mm);
- # Time::Zone and Date::Parse are part of the same distibution,
+ # Time::Zone and Date::Parse are part of the same distribution,
# and we need Time::Zone to deal with tz names like "EDT"
} elsif (eval { require Date::Parse }) {
$ts = Date::Parse::str2time($date);
@@ -138,7 +138,7 @@ sub time_response ($) {
}
sub msg_received_at ($) {
- my ($hdr) = @_; # Email::MIME::Header
+ my ($hdr) = @_; # PublicInbox::Eml
my @recvd = $hdr->header_raw('Received');
my ($ts);
foreach my $r (@recvd) {
@@ -153,7 +153,7 @@ sub msg_received_at ($) {
}
sub msg_date_only ($) {
- my ($hdr) = @_; # Email::MIME::Header
+ my ($hdr) = @_; # PublicInbox::Eml
my @date = $hdr->header_raw('Date');
my ($ts);
foreach my $d (@date) {
@@ -168,7 +168,7 @@ sub msg_date_only ($) {
# Favors Received header for sorting globally
sub msg_timestamp ($;$) {
- my ($hdr, $fallback) = @_; # Email::MIME::Header
+ my ($hdr, $fallback) = @_; # PublicInbox::Eml
my $ret;
$ret = msg_received_at($hdr) and return time_response($ret);
$ret = msg_date_only($hdr) and return time_response($ret);
@@ -177,7 +177,7 @@ sub msg_timestamp ($;$) {
# Favors the Date: header for display and sorting within a thread
sub msg_datestamp ($;$) {
- my ($hdr, $fallback) = @_; # Email::MIME::Header
+ my ($hdr, $fallback) = @_; # PublicInbox::Eml
my $ret;
$ret = msg_date_only($hdr) and return time_response($ret);
$ret = msg_received_at($hdr) and return time_response($ret);