QBI and pre-2018 PAL carryforward

Do pre-2018 disallowed PALs that are allowed in the current year count towards current year QBI, even if you still have remaining post-2017 QBI loss carryfoward? So for example, say I had pre-2018 PALs of 10,000, post-2017 QBI losses of 50,000 and current year gain of 30,000. In this case, is QBI 10,000 or 0?