Fix work calculation