removing trailing slashes and chomp()