theme registry replacement used nested array, fixed for compatibility with upstream