Fix regex for internet bill and update splitBill since it's just lil Cammy now
[SonOfLokstallBot.git] / src / rules.php
index 10a2110..8f57393 100644 (file)
@@ -15,7 +15,7 @@ return [
     ],
     'Internet' => [
         'imapQuery' => 'FROM "@online.telstra.com"',
-        'regex' => '/Total \$(?<amount>[0-9]+(\.[0-9]{2})?).*?Due Date (?<due>\d{1,2} \w{3} \d{4})/',
+        'regex' => '/Total.*?\$(?<amount>[0-9]+(\.[0-9]{2})?).*?Due Date.*?(?<due>\d{1,2} \w{3} \d{4})/',
         'messageTransform' => ∘(glue(" "), map('trim'), lines, 'strip_tags', 'html_entity_decode')
     ],
     'Gas' => [