Przeglądaj źródła

Fix retrieval of timestamp

primary
Mandragorat Wandystanu 1 rok temu
rodzic
commit
2ec2f2d462
1 zmienionych plików z 1 dodań i 1 usunięć
  1. +1
    -1
      byPeriodSlice.php

+ 1
- 1
byPeriodSlice.php Wyświetl plik

@@ -75,7 +75,7 @@ $summary = [];

foreach ($messages as $message) {
$sender = trim($xpath->evaluate('substring-before(substring-after(normalize-space(div[@class = "hidden-xs"]/following-sibling::text()[1]), "By "), " · #")', $message), '"');
$timestamp = $xpath->evaluate('substring-before(substring-after(.//script[@class = "timedisp"], "DisplayShortTime( "), " ,")', $message);
$timestamp = $xpath->evaluate('substring-before(substring-after(.//script[@class = "timedisp"], "DisplayShortTime("), ",")', $message);

$date = new DateTime(null, $tz);
$date->setTimestamp($timestamp / 1000000000);


Ładowanie…
Anuluj
Zapisz