Looks like inline if was backwards