Skip to content
Snippets Groups Projects
Commit 2fe010fd authored by Taras's avatar Taras
Browse files

Revert new room type

parent 5363d929
No related branches found
No related tags found
No related merge requests found
......@@ -70,7 +70,6 @@ class RoomRequestsDialogFragment : BaseFullscreenDialogFragment<DialogFragmentRo
CircleRoomTypeArg.Circle -> R.string.circle
CircleRoomTypeArg.Group -> R.string.group
CircleRoomTypeArg.Photo -> R.string.gallery
CircleRoomTypeArg.DM -> R.string.direct_messages
}
)
return getString(
......
package org.futo.circles.core.model
enum class CircleRoomTypeArg { Circle, Group, Photo, DM }
enum class CircleRoomTypeArg { Circle, Group, Photo }
fun CircleRoomTypeArg.toShareUrlType() = when (this) {
CircleRoomTypeArg.Circle -> ShareUrlTypeArg.TIMELINE
CircleRoomTypeArg.Group -> ShareUrlTypeArg.GROUP
CircleRoomTypeArg.Photo -> ShareUrlTypeArg.GALLERY
CircleRoomTypeArg.DM -> throw IllegalArgumentException("Share is not supported for DMs")
}
fun convertToStringRoomType(roomType: CircleRoomTypeArg) = when (roomType) {
CircleRoomTypeArg.Group -> GROUP_TYPE
CircleRoomTypeArg.Circle -> TIMELINE_TYPE
CircleRoomTypeArg.Photo -> GALLERY_TYPE
CircleRoomTypeArg.DM ->
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment