fix #390, properly handle null ownername at CalDAV calendars

This commit is contained in:
tibbi 2018-03-05 09:10:30 +01:00
parent 8d03a68d8b
commit 43ce8ec161
1 changed files with 1 additions and 1 deletions

View File

@ -64,7 +64,7 @@ class CalDAVHandler(val context: Context) {
val displayName = cursor.getStringValue(CalendarContract.Calendars.CALENDAR_DISPLAY_NAME) val displayName = cursor.getStringValue(CalendarContract.Calendars.CALENDAR_DISPLAY_NAME)
val accountName = cursor.getStringValue(CalendarContract.Calendars.ACCOUNT_NAME) val accountName = cursor.getStringValue(CalendarContract.Calendars.ACCOUNT_NAME)
val accountType = cursor.getStringValue(CalendarContract.Calendars.ACCOUNT_TYPE) val accountType = cursor.getStringValue(CalendarContract.Calendars.ACCOUNT_TYPE)
val ownerName = cursor.getStringValue(CalendarContract.Calendars.OWNER_ACCOUNT) val ownerName = cursor.getStringValue(CalendarContract.Calendars.OWNER_ACCOUNT) ?: ""
val color = cursor.getIntValue(CalendarContract.Calendars.CALENDAR_COLOR) val color = cursor.getIntValue(CalendarContract.Calendars.CALENDAR_COLOR)
val accessLevel = cursor.getIntValue(CalendarContract.Calendars.CALENDAR_ACCESS_LEVEL) val accessLevel = cursor.getIntValue(CalendarContract.Calendars.CALENDAR_ACCESS_LEVEL)
val calendar = CalDAVCalendar(id, displayName, accountName, accountType, ownerName, color, accessLevel) val calendar = CalDAVCalendar(id, displayName, accountName, accountType, ownerName, color, accessLevel)