Made the bs4 code simpler