Skip to content

Commit d22560a

Browse files
committed
Travis doesn't like my spaces; removed some.
1 parent 8cede3a commit d22560a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/Omnipay/Common/Message/AbstractRequest.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -178,13 +178,13 @@ public function setCardReference($value)
178178

179179
public function toFloat($value)
180180
{
181-
if ( ! is_string($value) && ! is_int($value) && ! is_float($value)) {
181+
if (!is_string($value) && ! is_int($value) && ! is_float($value)) {
182182
throw new InvalidRequestException('Data type is not a valid decimal number.');
183183
}
184184

185185
if (is_string($value)) {
186186
// Validate generic number, with optional sign and decimals.
187-
if ( ! preg_match('/^[-]?[0-9]+(\.[0-9]*)?$/', $value)) {
187+
if (!preg_match('/^[-]?[0-9]+(\.[0-9]*)?$/', $value)) {
188188
throw new InvalidRequestException('String is not a valid decimal number.');
189189
}
190190
}
@@ -210,20 +210,20 @@ public function getAmount()
210210
if (is_int($amount) || (is_string($amount) && false === strpos((string) $amount, '.'))) {
211211
throw new InvalidRequestException(
212212
'Please specify amount as a string or float, '
213-
. 'with decimal places (e.g. \'10.00\' to represent $10.00).'
213+
. 'with decimal places (e.g. \'10.00\' to represent $10.00).'
214214
);
215215
};
216216
}
217217

218218
$amount = $this->toFloat($amount);
219219

220220
// Check for a negative amount.
221-
if ( ! $this->negativeAmountAllowed && $amount < 0) {
221+
if (!$this->negativeAmountAllowed && $amount < 0) {
222222
throw new InvalidRequestException('A negative amount is not allowed.');
223223
}
224224

225225
// Check for a zero amount.
226-
if ( ! $this->zeroAmountAllowed && $amount === 0.0) {
226+
if (!$this->zeroAmountAllowed && $amount === 0.0) {
227227
throw new InvalidRequestException('A zero amount is not allowed.');
228228
}
229229

0 commit comments

Comments
 (0)