Remove extra appended '/' and add ability to use arrays for patterns