Removed duplicating code
Added missing use statement