// Last returns a last Log
Last returns a last Log
// Last returns a last Log
func (s Service) Last(ctx context.Context) (*Log, error) {
	mLog, err := s.repo.Last(ctx, &QueryCondition{
		Where:	&WhereCondition{
			Status:	StatusApplied,
		},
	})
	if err != nil {
		if errors.Is(err, apperror.ErrNotFound) {
			return nil, err
		}
		return nil, errors.Wrapf(apperror.ErrInternal, "migration.Service.Last error: %v", err)
	}
	return mLog, nil
}
func ( s Service ) Last ( ctx context . Context ) ( * Log , error ) { mLog , err := s . repo . Last ( ctx , & QueryCondition { Where : & WhereCondition { Status : StatusApplied , } , } ) if err != nil { if errors . Is ( err , apperror . ErrNotFound ) { return nil , err } return nil , errors . Wrapf ( apperror . ErrInternal , " " , err ) } return mLog , nil }
Last returns a last Log
Last returns a last Log