Created
January 6, 2016 22:28
-
-
Save audstanley/1a026c16341ab9b29b2e to your computer and use it in GitHub Desktop.
wont return the objects in the array
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var obj = [ {"username":"audstanleybot"} ]; | |
var newObj = '{"username":"audstanleybot2"}'; | |
function addToObj(anObj) { | |
return anObj.push(newObj); | |
} | |
console.log(addToObj(obj)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment