/
home
/
techb158
/
ileadtechnology.com
/
vendor
/
smodav
/
mpesa
/
src
/
Mpesa
/
Traits
/
/home/techb158/ileadtechnology.com/vendor/smodav/mpesa/src/Mpesa/Traits
mkdir
upload
Name
Size
Mode
Actions
UsesCore.php
1256
0644
edit
dl
rm
Validates.php
680
0644
edit
dl
rm
Edit:
/home/techb158/ileadtechnology.com/vendor/smodav/mpesa/src/Mpesa/Traits/Validates.php
(680B)
<?php namespace SmoDav\Mpesa\Traits; use InvalidArgumentException; trait Validates { /** * Check if the provided number is valid. * * @param string $number * * @throws InvalidArgumentException * * @return void */ protected function validateNumber($number) { } /** * Check if the amount is numeric. * * @param string|int|float $amount * * @throws InvalidArgumentException * * @return void */ protected function validateAmount($amount) { if (!is_numeric($amount)) { throw new InvalidArgumentException('The amount must be numeric'); } } }
Save