removed unnecessary calls to the getDefaultAdapter