Fixed indentation
Removed duplicate code
Added a metric for connection fallbacks