I have added if condition in the patch for the footer, Please review.