Update Text.php

$agent has been already defined