 				{
 					avatarBase64 = Base64.encodeByteArray(avatar);
 				}
-				catch(err:Error)
-				{
-					throw new Error("VCard:saveVCard Error encoding bytes " + err.getStackTrace());
+				catch(error:Error)
+				{
+					throw new Error("VCard:saveVCard Error encoding bytes " + error.getStackTrace());
 				}
 				
 				try

					
				vcardExtNode.appendChild( avatarNode );
			}

			iq.addExtension( vcardExt );
			connection.send( iq );

					binaryNode.appendChild(avatarBase64);
					avatarNode.appendChild(binaryNode);
				}
				catch(error:Error)
				{
					throw new Error("VCard:saveVCard Error converting bytes to string " + error.message);
				}

				var typeNode:XML = <TYPE/>;
