Fix check for https