User:Cqm/test.js

var api = new mw.Api api .get( {		action: 'query',		list: 'abuselog',		aflfilter: '45',		aflprop: 'details',		afllimit: 'max'	} ) .done( function ( data ) {		var comments = data.query.abuselog,			arr = [],			x, y, i;

for ( i = 0; i < comments.length; i++ ) { x = comments[i].details; y = JSON.parse( x.added_lines ) y.user = x.user_name y.page = x.article_text.replace( 'Feedback/', '' ) arr.push( y ); }

console.log( arr ); } )