Cleaned up code

Signed-off-by: Levi Gross <levi@levigross.com>
Readded http and https check

Signed-off-by: Levi Gross <levi@levigross.com>