fixed bug in fallback to legacy