Fix notice/warning for file-less items. Fix #470.