fix: check if packFormat is valid for resourcepack parsing

Signed-off-by: Ryan Cao <70191398+ryanccn@users.noreply.github.com>
This commit is contained in:
Ryan Cao 2022-11-19 23:42:56 +08:00
parent b1bdc6f745
commit f527958cb3
No known key found for this signature in database

View File

@ -117,5 +117,5 @@ bool ResourcePack::applyFilter(QRegularExpression filter) const
bool ResourcePack::valid() const bool ResourcePack::valid() const
{ {
return m_pack_format != 0; return s_pack_format_versions.contains(m_pack_format);
} }