Buggy code:
@ Inject private LibraryServiceAsync libraryService ; @ Inject private AnalyticsServiceAsync analyticService ; private SimpleAsyncCallback < CommentsListDo > commentsListDoAsync ; private CollectionDo collectionDo = null ; private CollectionPlayerPresenter collectionPlayerPresenter = null ; private PreviewHomePresenter previewHomePresenter ; private PreviewEndPresenter previewEndPresenter ; private CollectionHomeMetadataPresenter collectionHomeMetadataPresenter ; private CollectionSummaryIndividualPresenter collectionSummaryIndividualPresenter ; public static final Object METADATA_PRESENTER_SLOT = new Object ( ) ; private static final String PAGE = "course-page" ; private static final String CREATE = "CREATE" ; private static final String EDIT = "EDIT" ; private static final String FEATCHINGCOMMENT = "FEATCHINGCOMMENT" ; private static final String INITIAL_COMMENT_LIMIT = "10" ; private static final String INITIAL_OFFSET = "0" ; public static final Object COLLECTION_REPORTS_SLOT = new Object ( ) ; PrintUserDataDO printData = new PrintUserDataDO ( ) ; private MessageProperties i18n = GWT . create ( MessageProperties . class ) ; int count = 0 ; @ Inject public CollectionEndPresenter ( EventBus eventBus , IsCollectionEndView view , PreviewHomePresenter previewHomePresenter , PreviewEndPresenter previewEndPresenter , CollectionHomeMetadataPresenter collectionHomeMetadataPresenter , CollectionSummaryIndividualPresenter collectionSummaryIndividualPresenter ) { } public void setCollectionMetadata ( final CollectionDo collectionDo ) { } public void displayAuthorDetails ( boolean isDisplayDetails ) { } public void setPreviewHomePresenter ( ) { } public void setPreviewEndPresenter ( ) { } public void setStudyEndPage ( ) { } public void setCollectionHomeMetadata ( ) { } public void setCollectionSummaryBasedOnClasspageIdSessionId ( ) { } public void setCollectionSummaryData ( String collectionId , String classpageId , String userId , String sessionId , PrintUserDataDO printData ) { } public void clearslot ( ) { } public void setViewCount ( String viewCount ) { } public void updateLikesCount ( int likesCount ) { } public void setUserProfileName ( String gooruUid ) { } public void resetMetadataFields ( ) { } public PlayerAppServiceAsync getPlayerAppService ( ) { } public void setPlayerAppService ( PlayerAppServiceAsync playerAppService ) { } public SimpleAsyncCallback < CommentsListDo > getCommentsListDoAsync ( ) { } public void setCommentsListDoAsync ( SimpleAsyncCallback < CommentsListDo > commentsListDoAsync ) { } @ Override public void setPlayerLoginStatusHandler ( boolean isLoggedIn ) { } private void getCollectionCommentsList ( String gooruOid , final String offset , String limit ) { } @ Override public void createCommentForCollection ( String gooruOid , String comment ) { } public void updateCommentChildView ( String commentUid , String action ) { } @ Override public void deleteCommentFromCollection ( final String gooruOid , String commentUid , final String offset , final String limit , String commentText ) { } public void insertCommentAfterDeletion ( final String gooruOid , final String offset , String limit ) { } public void editCommentChildView ( String commentUid , String commentText , String action ) { } @ Override public void getPaginationResults ( String gooruOid , String offset , String limit ) { } public void getFlagedReport ( String gooruOid ) { } public void setRelatedConcepts ( final CollectionDo collectionDo ) { } public void getNextCollectionDetails ( String gooruOid , String page , final String subject , final String lessonId , final String libraryType ) { } public void setCollectionDoOnRefresh ( CollectionDo collectionDo ) { } public CollectionPlayerPresenter getCollectionPlayerPresenter ( ) { } public void setCollectionPlayerPresenter ( CollectionPlayerPresenter collectionPlayerPresenter ) { } public void setTeacherInfo ( ClasspageItemDo classpageItemDo ) { } public void setDataInsightsSummaryUrl ( String sessionId ) { } public void setDataInsightsUrl ( ) { } public Button getBackToClassButton ( ) { } public void clearDashBoardIframe ( ) { } public void setClasspageInsightsUrl ( String classpageId , String sessionId ) { } @ Override public void resetCollectionActivityEventId ( ) { } @ Override public void triggerCollectionShareDataEvent ( String collectionId , String itemType , String shareType , boolean confirmStatus ) { } public void displaySpendTime ( Long hours , Long mins , Double secs ) { } public void displayScoreCount ( Integer collectionScore , Integer noOfQuestions ) { } @ Override public void getAvgReaction ( ) { } public void showAvgReaction ( Integer averageReaction ) { } public void dispalyTime ( ) { } @ Override public void updateCommentsStatus ( String commentsStatus ) { } public void changeCommentsButton ( CollectionDo collectionDoObj ) { } public AnalyticsServiceAsync getAnalyticService ( ) { } public void setAnalyticService ( AnalyticsServiceAsync analyticService ) { } @ Override public void getSessionsDataByUser ( final String collectionId , final String classId , final String userId ) { this . analyticService . getSessionsDataByUser ( collectionId , classId , userId , new com . google . gwt . user . client . rpc . AsyncCallback < java . util . ArrayList < CollectionSummaryUsersDataDo > > ( ) { @ Override public void onSuccess ( java . util . ArrayList < CollectionSummaryUsersDataDo > result ) { if ( ( result . size ( ) ) != 0 ) { int day = result . get ( ( ( result . size ( ) ) - 1 ) ) . getFrequency ( ) ; printData . setUserName ( null ) ; printData . setSession ( ( ( day + ( AnalyticsUtil . getOrdinalSuffix ( day ) ) ) + "<seq2seq4repair_space>Session" ) ) ; <START_BUG> printData . setSessionStartTime ( AnalyticsUtil . getCreatedTime ( Long . toString ( result . get ( ( ( result . size ( ) ) - 1 ) ) . getTimeStamp ( ) ) ) ) ; <END_BUG> getCollectionMetaDataByUserAndSession ( collectionId , classId , userId , result . get ( ( ( result . size ( ) ) - 1 ) ) . getSessionId ( ) , printData ) ; getView ( ) . setSessionsData ( result ) ; } else { clearSlot ( CollectionEndPresenter . COLLECTION_REPORTS_SLOT ) ; getView ( ) . hidePanel ( ) ; collectionSummaryIndividualPresenter . setNoDataMessage ( getView ( ) . getLoadingImageLabel ( ) ) ; setInSlot ( CollectionEndPresenter . COLLECTION_REPORTS_SLOT , collectionSummaryIndividualPresenter , false ) ; } } @ Override public void onFailure ( Throwable caught ) { } } ) ; } @ Override public void getCollectionMetaDataByUserAndSession ( final String collectionId , final String classId , final String userId , final String sessionId , final PrintUserDataDO printData ) { } }

Fix:
printData . setSessionStartTime ( AnalyticsUtil . getSessionsCreatedTime ( Long . toString ( result . get ( ( ( result . size ( ) ) - 1 ) ) . getTimeStamp ( ) ) ) ) ;