Fix raid size not adjusting bug
This commit is contained in:
@@ -56,8 +56,6 @@ export default function CalendarDisplay({
|
||||
|
||||
const showEditCalendarEventModal = (eventClickArg: EventClickArg) => {
|
||||
const calendarEvent = calendarEvents.find((calEvent) => calEvent.calendarEventId === eventClickArg.event.id);
|
||||
console.log("calendarEvent");
|
||||
console.log(calendarEvent);
|
||||
if(raidGroupId && calendarEvent?.gameId){
|
||||
setDisableModal(true);
|
||||
}
|
||||
|
||||
@@ -45,7 +45,11 @@ export default function RaidInstanceHeader(){
|
||||
|
||||
const updateRaidSize = (newRaidSize: number) => {
|
||||
if(newRaidSize > (raidInstance?.raidSize ?? 0)){
|
||||
setSelectedClassGroups([...selectedClassGroups, null]);
|
||||
const newClassGroups = [...selectedClassGroups];
|
||||
while(newClassGroups.length < newRaidSize){
|
||||
newClassGroups.push(null);
|
||||
}
|
||||
setSelectedClassGroups(newClassGroups);
|
||||
}
|
||||
else{
|
||||
setSelectedClassGroups(selectedClassGroups.slice(0, newRaidSize));
|
||||
|
||||
Reference in New Issue
Block a user