package Ġz d . zero . wa ifu . mot iv ator . plugin . on boarding Ċ Ċ import Ġcom . intellij . ide . plugins . PluginManager Core Ċ import Ġcom . intellij . openapi . application . Application Manager Ċ import Ġcom . intellij . openapi . extensions . Plugin Id Ċ import Ġcom . intellij . openapi . project . Project Manager Ċ import Ġz d . zero . wa ifu . mot iv ator . plugin . Wa ifu Mot iv ator Ċ import Ġz d . zero . wa ifu . mot iv ator . plugin . platform . Update Assets Listener Ċ import Ġz d . zero . wa ifu . mot iv ator . plugin . settings . Wa ifu Mot iv ator Plugin State Ċ import Ġz d . zero . wa ifu . mot iv ator . plugin . tools . to Optional Ċ import Ġjava . util . Optional Ċ import Ġjava . util . UUID Ċ Ċ object ĠUser On boarding Ġ{ ĊĊĠĠĠ Ġfun Ġattempt To Perform New Update Actions () Ġ{ ĊĠĠĠĠĠĠĠ Ġget New Version (). if Present Ġ{ Ġnew Version Ġ-> ĊĠĠĠĠĠĠĠĠĠĠĠ ĠW a ifu Mot iv ator Plugin State . get Plugin State (). version Ġ= Ġnew Version ĊĠĠĠĠĠĠĠĠĠĠĠ ĠApplication Manager . getApplication (). message Bus ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ. sync Publisher ( Update Assets Listener . TOPIC ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ. on Requested Update () ĊĠĠĠĠĠĠĠĠĠĠĠ ĠUpdate Notification . display ( Project Manager . getInstance (). default Project , Ġnew Version ) ĊĠĠĠĠĠĠĠ Ġ} ĊĊĠĠĠĠĠĠĠ Ġif Ġ( Wa ifu Mot iv ator Plugin State . get Plugin State (). userId . isEmpty ()) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠW a ifu Mot iv ator Plugin State . get Plugin State (). userId Ġ= ĠUUID . randomUUID (). toString () ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġprivate Ġfun Ġget New Version () Ġ= ĊĠĠĠĠĠĠĠ Ġget Version () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. filter Ġ{ Ġit Ġ!= ĠW a ifu Mot iv ator Plugin State . get Plugin State (). version Ġ} ĊĊĠĠĠ Ġfun Ġis New Version () Ġ= ĊĠĠĠĠĠĠĠ Ġget New Version (). isPresent ĊĊĠĠĠ Ġprivate Ġfun Ġget Version (): ĠOptional < String > Ġ= ĊĠĠĠĠĠĠĠ ĠPlugin Manager Core . get Plugin ( Plugin Id . getId ( Wa ifu Mot iv ator . PLUGIN _ ID )) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. to Optional () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. map Ġ{ Ġit . version Ġ} Ċ } Ċ