Skip to content

Instantly share code, notes, and snippets.

@delineas delineas/payment.php Secret
Last active Sep 9, 2019

Embed
What would you like to do?
Reto Refactorización WRP 34
<?php
class Payment {
// ... mas codigo
function getCantidades()
{
if ($this->isDead)
$result = $this->deadAmount();
else {
if ($this->isSeparated)
$result = $this->separatedAmount();
else {
if (!$this->isRetired)
$result = $this->normalPayAmount();
else
$result = $this->retiredAmount();
}
}
return $result;
}
// ... mas codigo
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.