added namespaces for before and after