mirror of
				https://github.com/firefly-iii/firefly-iii.git
				synced 2025-10-31 02:36:28 +00:00 
			
		
		
		
	Stop escaping notes, move to parser.
This commit is contained in:
		| @@ -41,8 +41,7 @@ use Symfony\Component\HttpFoundation\ParameterBag; | ||||
|  */ | ||||
| class ShowController extends Controller | ||||
| { | ||||
|     /** @var TransactionGroupRepositoryInterface */ | ||||
|     private $repository; | ||||
|     private TransactionGroupRepositoryInterface $repository; | ||||
|  | ||||
|     /** | ||||
|      * ShowController constructor. | ||||
| @@ -103,12 +102,7 @@ class ShowController extends Controller | ||||
|         $amounts = $this->getAmounts($groupArray); | ||||
|         $accounts = $this->getAccounts($groupArray); | ||||
|  | ||||
|         // make sure notes are escaped but not double escaped. | ||||
|         foreach ($groupArray['transactions'] as $index => $transaction) { | ||||
|             $search = ['&', '>', '<']; | ||||
|             if (!Str::contains($transaction['notes'], $search)) { | ||||
|                 $groupArray['transactions'][$index]['notes'] = e($transaction['notes']); | ||||
|             } | ||||
|             $groupArray['transactions'][$index]['tags'] = $this->repository->getTagObjects($groupArray['transactions'][$index]['transaction_journal_id']); | ||||
|         } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user