adjusted optionals + changed slog to println