@@ -164,7 +164,7 @@ export default function useRoller() {
166 const fetchConfig = useCallback(async () => {
166 const fetchConfig = useCallback(async () => {
167− getNextQuotaTime(1);
167+ getNextQuotaTime(Date.now() + 1000);
169 .getRollerConfig()
169 .getRollerConfig()
170 .then(config => {
170 .then(config => {
@@ -184,12 +184,12 @@ export default function useRoller() {
184 if (point.l2Quota <= 0) {
184 if (point.l2Quota <= 0) {
185 setModalText(
185 setModalText(
186 `You have reached your weekly L2 transaction limit. You will get another
186 `You have reached your weekly L2 transaction limit. You will get another
187− ${config?.rollerQuota} transactions on ${ddmmmYYYY(nextQuotaTime)}.`
187+ ${point.l2Allowance} transactions on ${ddmmmYYYY(nextQuotaTime)}.`
191 return point.l2Quota <= 0;
191 return point.l2Quota <= 0;
192− }, [config, nextQuotaTime, point, setModalText]);
192+ }, [nextQuotaTime, point, setModalText]);
194 const initPoint = useCallback(
194 const initPoint = useCallback(
195 async (point: string | number) => {
195 async (point: string | number) => {
@@ -203,9 +203,9 @@ export default function useRoller() {
203 const pointNum = Number(point);
203 const pointNum = Number(point);
205 const rawDetails = await api.getPoint(pointNum);
205 const rawDetails = await api.getPoint(pointNum);
206− const l2Quota = isL2Spawn(rawDetails?.dominion)
206+ const isL2 = isL2Spawn(rawDetails?.dominion);
207− ? await api.getRemainingQuota(pointNum)
207+ const l2Quota = isL2 ? await api.getRemainingQuota(pointNum) : 0;
208− : 0;
208+ const l2Allowance = isL2 ? await api.getAllowance(pointNum) : 0;
210 const details = isL2Spawn(rawDetails?.dominion)
210 const details = isL2Spawn(rawDetails?.dominion)
211 ? toL1Details(rawDetails)
211 ? toL1Details(rawDetails)
@@ -216,6 +216,7 @@ export default function useRoller() {
217 address: _wallet.address,
217 address: _wallet.address,
220 } catch (e) {
221 } catch (e) {
221 console.warn(e);
222 console.warn(e);