Revised to do concatenation instead of splice