convert the article controller to handle multiple patterns properly