Add samo if`s to the function