add None check for variable node[local_repo]

Change-Id: Ia8b5c6542b2ea18c888eb2d4479144cb19a7e584