define('INSTALLDIR', realpath(__DIR__ . '/../../..'));
$shortoptions = 'l::a::i';
-$longoptions = ['limit=','all','image'];
+$longoptions = ['limit=', 'all', 'image'];
$helptext = <<<END_OF_HELP
remove_remote_media.php [options]
END_OF_HELP;
-require_once INSTALLDIR.'/scripts/commandline.inc';
+require_once INSTALLDIR . '/scripts/commandline.inc';
$quiet = have_option('q', 'quiet');
$include_previews = have_option('a', 'all');
}
$query = "
- SELECT
+ SELECT DISTINCT
file_to_post.file_id
FROM
file_to_post