added diff functionality