code cleanup for validation - only twitter widget does not