Javascript Has Property Check