From 875e3fa5307f50f37ffbcced2e60aa9d5a03d3b0 Mon Sep 17 00:00:00 2001 From: Isira Seneviratne Date: Sun, 1 Sep 2024 17:45:11 +0530 Subject: [PATCH] Reduce some lines of code --- .../ui/components/video/VideoDescriptionSection.kt | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/ui/components/video/VideoDescriptionSection.kt b/app/src/main/java/org/schabi/newpipe/ui/components/video/VideoDescriptionSection.kt index f43092b83da..62d4c1dc563 100644 --- a/app/src/main/java/org/schabi/newpipe/ui/components/video/VideoDescriptionSection.kt +++ b/app/src/main/java/org/schabi/newpipe/ui/components/video/VideoDescriptionSection.kt @@ -160,12 +160,10 @@ fun VideoDescriptionSection(streamInfo: StreamInfo) { } } - if (streamInfo.ageLimit != StreamExtractor.NO_AGE_LIMIT) { + val ageLimit = streamInfo.ageLimit + if (ageLimit != StreamExtractor.NO_AGE_LIMIT) { item { - MetadataItem( - title = R.string.metadata_age_limit, - value = streamInfo.ageLimit.toString() - ) + MetadataItem(title = R.string.metadata_age_limit, value = ageLimit.toString()) } }