core: Make get_histtype return HIST_DEFAULT if needed