fixing deprecated syntax