api.py: Adds overlay type checking

Checks have been added to determine whether or not to readd a repo
if the overlay type reported from the remotedb is different from the
overlay type reported by the local db.