Fix some decrypt bugs.

This commit is contained in:
James Cole 2016-03-12 07:17:00 +01:00
parent ce09da084c
commit 6f95e9a3cb

View File

@ -56,7 +56,6 @@ use Watson\Validating\ValidatingTrait;
* @property-read string $source_account_id
* @property-read string $source_account_name
* @property-read string $source_account_type
*
*/
class TransactionJournal extends TransactionJournalSupport
@ -186,9 +185,13 @@ class TransactionJournal extends TransactionJournalSupport
*/
public function getDestinationAccountNameAttribute($value)
{
if (!is_null($value) && strlen(strval($value)) > 0) {
return Crypt::decrypt($value);
}
return null;
}
/**
*
* @param string $fieldName
@ -213,9 +216,14 @@ class TransactionJournal extends TransactionJournalSupport
*/
public function getSourceAccountNameAttribute($value)
{
if (!is_null($value) && strlen(strval($value)) > 0) {
return Crypt::decrypt($value);
}
return null;
}
/**
* @return bool
*/