Added __main__ check