private static User GetUser(NpgsqlDataReader reader) { return new User { Id = reader.GetInt64(0), Name = reader.GetString(1), Description = reader.GetString(2), Photo = reader.GetByteArray(3), Enabled = reader.GetBoolean(4), CanChange = reader.GetBoolean(5), Privilege = reader.GetNullableInt32(6) }; }