Fix buildqueue crash when building images without a profile