added an example showing an optional second parameter for contents method