package game_service

import (
	"evening_detective_server/internal/modules/storytelling"
	"evening_detective_server/internal/repos"
)

func mapApplications(o []*repos.Application) []*storytelling.Application {
	res := make([]*storytelling.Application, 0, len(o))
	for _, item := range o {
		res = append(res, mapApplication(item))
	}
	return res
}

func mapApplication(o *repos.Application) *storytelling.Application {
	return &storytelling.Application{
		Name:  o.Name,
		Image: o.Image,
	}
}
