Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
class TaxCalculationSaver
def self.save_taxes!(payroll)
total_tax_amount = payroll.employees.map do |employee|
TaxCalculator.calculate(payroll, employee)
end.sum
PayrollSaver.save!(payroll, total_tax_amount: total_tax_amount)
end
end
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.