Fixed issues from comments

Add const for contract_type and add HTMLPurifier

Fix CS and refactoring

Removed SensioLabsConnectBundle

Renamed forms action

Fixed method visibility

Cleaned tests