Convert static constructor to method