mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-31 02:55:58 +01:00 
			
		
		
		
	sort plugins alphabetically
This commit is contained in:
		| @@ -668,12 +668,13 @@ var fs = require('fs'), | ||||
| 					} | ||||
|  | ||||
| 					pluginArray.sort(function(a, b) { | ||||
| 						if(a.installed && !b.installed) { | ||||
| 							return -1; | ||||
| 						} else if(!a.installed && b.installed) { | ||||
| 						if (a.name > b.name ) { | ||||
| 							return 1; | ||||
| 						} else if (a.name < b.name ){ | ||||
| 							return -1; | ||||
| 						} else { | ||||
| 							return 0; | ||||
| 						} | ||||
| 						return 0; | ||||
| 					}); | ||||
|  | ||||
| 					callback(null, pluginArray); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user