fixed ETag middleware for rails apps