Use the following function to reset queries

wp_reset_query()