Looks like $modified wasn't defined.