Replace checking domain exist function