Added settings check to hook.