Looks like a copy/pasted code doing more or less the same thing.