I think this should do it. Good luck!
#target illustrator
// it's best practice to wrap everything in a function
// so that you don't accidentally mess up any global
// variables
function RemoveNoStrokePaths() {
// if there are no documents open then return, otherwise
// store a reference to the active document in 'doc'
if( !app.documents.length ) return;
var doc = app.activeDocument;
// store a reference to all the PathItems in the active document
var paths = doc.pathItems;
// Since we might be removing items from the list, the item indices
// could change, and so should loop from the last index to the first
for( var i = paths.length-1; i >= 0; i-- ) {
// get reference to the current PathItem
var curPath = paths;
// if the PathItem has a stroke assigned, the 'stroked' property
// will equal 'true', so if it's false we know that the path
// doesn't have a stroke and we can remove it
if( !curPath.stroked )
curPath.remove();
}
}
RemoveNoStrokePaths();