some updates in code samples