# removeSingletonIfCreated method

1. @protected

bool removeSingletonIfCreated(

1. String name

)

Removes a singleton pod if it has been created.

This method checks if a singleton pod has been created and removes it from the singleton cache if it has.

`name` the name of the singleton pod to remove Returns `true` if the singleton pod was removed, `false` otherwise

## Implementation

    @protected
    bool removeSingletonIfCreated(String name) {
    		if (!_alreadyCreated.contains(name)) {
    			removeSingleton(name);
    			return true;
    		} else {
    			return false;
    		}
    	}