File tree Expand file tree Collapse file tree 3 files changed +20
-4
lines changed
Expand file tree Collapse file tree 3 files changed +20
-4
lines changed Original file line number Diff line number Diff line change 11{
22 "manifest_version" : 3 ,
33 "name" : " OnlyFans Cookie Helper" ,
4- "version" : " 2.2.1 " ,
4+ "version" : " 2.3.0 " ,
55 "description" : " Helper extension that makes it easier to copy config.json values for the DIGITALCRIMINALS/OnlyFans scraper" ,
66 "icons" : {
77 "48" : " icons/cookie.png"
Original file line number Diff line number Diff line change 11{
22 "manifest_version" : 2 ,
33 "name" : " OnlyFans Cookie Helper" ,
4- "version" : " 2.2.1 " ,
4+ "version" : " 2.3.0 " ,
55 "description" : " Helper extension that makes it easier to copy config.json values for the DIGITALCRIMINALS/OnlyFans scraper" ,
66 "icons" : {
77 "48" : " icons/cookie.png"
Original file line number Diff line number Diff line change @@ -53,18 +53,34 @@ async function getContainers()
5353 /**
5454 * Non-Firefox browser or containers not enabled.
5555 */
56- if ( browser . contextualIdentities === undefined ) {
56+ if ( ! containersEnabled ) {
5757 return ;
5858 }
5959
6060 /**
6161 * Containers are enabled, but none found.
6262 */
63- const containers = await browser . contextualIdentities . query ( { } ) ;
63+ let containers = await browser . contextualIdentities . query ( { } ) ;
6464 if ( containers . length < 1 ) {
6565 return ;
6666 }
6767
68+ // Sort container list by name.
69+ containers . sort ( function ( a , b ) {
70+ const nameA = a . name . toLowerCase ( ) ;
71+ const nameB = b . name . toLowerCase ( ) ;
72+
73+ if ( nameA < nameB ) {
74+ return - 1 ;
75+ }
76+
77+ if ( nameA > nameB ) {
78+ return 1 ;
79+ }
80+
81+ return 0 ;
82+ } ) ;
83+
6884 const containerSection = document . querySelector ( '#container-list' ) ;
6985 containerSection . classList . remove ( 'hidden' ) ;
7086
You can’t perform that action at this time.
0 commit comments