finished major changes to pug