(collection: CharacterCollection)
| 240 | // --------------------------------------------------------------------------- |
| 241 | |
| 242 | export function getActiveCharacter(collection: CharacterCollection): CharacterConfig { |
| 243 | return ( |
| 244 | collection.items[collection.activeId] ?? Object.values(collection.items)[0] ?? DEFAULT_CHARACTER |
| 245 | ); |
| 246 | } |
| 247 | |
| 248 | export function getCharacterList(collection: CharacterCollection): CharacterConfig[] { |
| 249 | return Object.values(collection.items); |
no outgoing calls
no test coverage detected