forked from OpenWF/SpaceNinjaServer
		
	chore: simplify conversion of missionReward from PE+ (#1018)
Reviewed-on: OpenWF/SpaceNinjaServer#1018
This commit is contained in:
		
							parent
							
								
									a27f1c5e01
								
							
						
					
					
						commit
						3945359e7d
					
				@ -351,7 +351,7 @@ export const addFixedLevelRewards = (
 | 
				
			|||||||
    if (rewards.items) {
 | 
					    if (rewards.items) {
 | 
				
			||||||
        for (const item of rewards.items) {
 | 
					        for (const item of rewards.items) {
 | 
				
			||||||
            MissionRewards.push({
 | 
					            MissionRewards.push({
 | 
				
			||||||
                StoreItem: item.includes(`/StoreItems/`) ? item : `/Lotus/StoreItems${item.substring("Lotus/".length)}`,
 | 
					                StoreItem: item,
 | 
				
			||||||
                ItemCount: 1
 | 
					                ItemCount: 1
 | 
				
			||||||
            });
 | 
					            });
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
@ -359,9 +359,7 @@ export const addFixedLevelRewards = (
 | 
				
			|||||||
    if (rewards.countedItems) {
 | 
					    if (rewards.countedItems) {
 | 
				
			||||||
        for (const item of rewards.countedItems) {
 | 
					        for (const item of rewards.countedItems) {
 | 
				
			||||||
            MissionRewards.push({
 | 
					            MissionRewards.push({
 | 
				
			||||||
                StoreItem: item.ItemType.includes(`/StoreItems/`)
 | 
					                StoreItem: `/Lotus/StoreItems${item.ItemType.substring("Lotus/".length)}`,
 | 
				
			||||||
                    ? item.ItemType
 | 
					 | 
				
			||||||
                    : `/Lotus/StoreItems${item.ItemType.substring("Lotus/".length)}`,
 | 
					 | 
				
			||||||
                ItemCount: item.ItemCount
 | 
					                ItemCount: item.ItemCount
 | 
				
			||||||
            });
 | 
					            });
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user