redundant code in is_active_trail