cleaned up file structure, api only works on safari