Update gateway.php