Changeset 59 for trunk


Ignore:
Timestamp:
Sep 16, 2020, 11:15:46 AM (4 years ago)
Author:
chronos
Message:
  • Fixed: Possible empty email parsed from meet message.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/Meet/Meet.php

    r57 r59  
    259259    $Pattern = '/[a-z0-9_\-\+\.]+@[a-z0-9\-]+\.([a-z]{2,4})(?:\.[a-z]{2})?/i';
    260260    preg_match_all($Pattern, $Text, $Matches);
    261     if (count($Matches) > 0)
     261    if ((count($Matches) > 0) and ($Matches[0][0] != ''))
     262    {
    262263      $Result = $Matches[0][0];
     264    }
    263265  }
    264266  return $Result;
     
    443445        else $Weight = $this->Weight;
    444446      $this->Database->insert('MeetItem', array(
     447        'Source' => $this->Source,
     448        'Link' => $this->Link,
     449        'Email' => $this->Email,
    445450        'Message' => $this->Message,
    446451        'Time' => TimeToMysqlDateTime($this->Time),
    447452        'Gender' => $this->Gender,
    448453        'Age' => $Age,
    449         'Email' => $this->Email,
    450454        'Phone' => $this->Phone,
    451455        'Name' => $this->Name,
     
    453457        'Weight' => $Weight,
    454458        'Location' => $this->Location,
    455         'Source' => $this->Source,
    456         'Link' => $this->Link,
    457459        'RemoteId' => $this->RemoteId,
    458460        'TimeImport' => 'NOW()',
Note: See TracChangeset for help on using the changeset viewer.