Library conflict! Don't know how to resolve

Here's what I did to fix it. Well to compile at least I don't know if this will actually work to access the SD. The wasn't actually part of my project I assume all the libraries get loaded even if you aren't using them.

The solution that worked for me:
Sketch -> Include Library -> Contributed Libraries -> SD(esp32)

Note insert this before the main library:
#include <M5Core2.h>

What you will get is the following:
#include <sd_defines.h>
#include <sd_diskio.h>
#include <SD.h>

The reason I'm not sure if this is the correct is I already have a esp board installed so the library may be for that.

I wish Arduino had a better way to manage libraries . Like a way to group them for projects.