Changed all configuration, Added filter , cleaned code