Logic simplified to improve plugin performance and size.
Plugin size detail updated.