Simplified Variant and fixed broken json loading code