Added logging, removed Enum, bookkeeping