Use proper Kotlin syntax #7

Closed
opened 3 years ago by Seil0 · 0 comments
Seil0 commented 3 years ago
Owner

For example:

replace

val result = CourseListParser().getCourseLinks(courseListURL)
if (result != null) {
   courseList = CourseList(CourseMeta(System.currentTimeMillis() / 1000, result.size), result)
}

with

CourseListParser().getCourseLinks(courseListURL)?.let{
   courseList = CourseList(CourseMeta(System.currentTimeMillis() / 1000, it.size), it)
}
For example: replace ```kotlin val result = CourseListParser().getCourseLinks(courseListURL) if (result != null) { courseList = CourseList(CourseMeta(System.currentTimeMillis() / 1000, result.size), result) } ``` with ```kotlin CourseListParser().getCourseLinks(courseListURL)?.let{ courseList = CourseList(CourseMeta(System.currentTimeMillis() / 1000, it.size), it) } ```
Seil0 self-assigned this 3 years ago
Seil0 added the due date 2019-10-02 3 years ago
Seil0 modified the due date to 2019-10-01 from 2019-10-02 3 years ago
Seil0 added the
code/internal
label 3 years ago
Seil0 modified the due date to 2019-10-20 from 2019-10-01 3 years ago
Seil0 closed this issue 3 years ago
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date

2019-10-20

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.

Du besuchst diese Seite mit einem veralteten IPv4-Internetzugang. Möglicherweise treten in Zukunft Probleme mit der Erreichbarkeit und Performance auf. Bitte frage deinen Internetanbieter oder Netzwerkadministrator nach IPv6-Unterstützung.
You are visiting this site with an outdated IPv4 internet access. You may experience problems with accessibility and performance in the future. Please ask your ISP or network administrator for IPv6 support.
Weitere Infos | More Information
Klicke zum schließen | Click to close