added an example showing an optional second parameter for contents method

just thought that this might be quite a common usecase which is not documented at all