package Ġdev . sim on as . fade c andy rest . services Ċ Ċ import Ġio . ktor . application . Application Call Ċ import Ġio . ktor . http . HttpStatusCode Ċ import Ġio . ktor . response . respond Ċ Ċ suspend Ġfun Ġ< T > ĠApplication Call . respond With Result ( result : ĠResult < T >) Ġ{ ĊĠĠĠ Ġval Ġresponse Ġ= ĠResponse ( result ) ĊĠĠĠ Ġval ĠstatusCode Ġ= Ġwhen Ġ{ ĊĠĠĠĠĠĠĠ Ġresult . is Success Ġ-> HttpStatusCode . OK ĊĠĠĠĠĠĠĠ Ġelse Ġ-> ĠHttpStatusCode . InternalServerError ĊĠĠĠ Ġ} ĊĠĠĠ Ġrespond ( statusCode , Ġresponse ) Ċ }