mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-03 21:43:21 +00:00 
			
		
		
		
	user_topics: Rename set_muted_topics to set_user_topics.
We should now rename set_muted_topics to set_user_topics as with the new user_topic event, there will be various types of user-topic configurations to handle other than just muting topics.
This commit is contained in:
		
				
					committed by
					
						
						Tim Abbott
					
				
			
			
				
	
			
			
			
						parent
						
							03d9418010
						
					
				
				
					commit
					0d9b1547ce
				
			@@ -44,7 +44,7 @@ stream_data.add_sub(social);
 | 
			
		||||
 | 
			
		||||
function test(label, f) {
 | 
			
		||||
    run_test(label, ({override}) => {
 | 
			
		||||
        user_topics.set_muted_topics([]);
 | 
			
		||||
        user_topics.set_user_topics([]);
 | 
			
		||||
        muted_users.set_muted_users([]);
 | 
			
		||||
        f({override});
 | 
			
		||||
    });
 | 
			
		||||
@@ -189,7 +189,7 @@ test("unknown streams", () => {
 | 
			
		||||
test("set_user_topics", () => {
 | 
			
		||||
    blueslip.expect("warn", "Unknown stream ID in set_user_topic: 999");
 | 
			
		||||
 | 
			
		||||
    user_topics.set_muted_topics([]);
 | 
			
		||||
    user_topics.set_user_topics([]);
 | 
			
		||||
    assert.ok(!user_topics.is_topic_muted(social.stream_id, "breakfast"));
 | 
			
		||||
    assert.ok(!user_topics.is_topic_muted(design.stream_id, "typography"));
 | 
			
		||||
 | 
			
		||||
@@ -243,9 +243,9 @@ test("set_user_topics", () => {
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
test("case_insensitivity", () => {
 | 
			
		||||
    user_topics.set_muted_topics([]);
 | 
			
		||||
    user_topics.set_user_topics([]);
 | 
			
		||||
    assert.ok(!user_topics.is_topic_muted(social.stream_id, "breakfast"));
 | 
			
		||||
    user_topics.set_muted_topics([
 | 
			
		||||
    user_topics.set_user_topics([
 | 
			
		||||
        {
 | 
			
		||||
            stream_id: social.stream_id,
 | 
			
		||||
            topic_name: "breakfast",
 | 
			
		||||
 
 | 
			
		||||
@@ -23,7 +23,7 @@ const params = {
 | 
			
		||||
function test(label, f) {
 | 
			
		||||
    run_test(label, ({override}) => {
 | 
			
		||||
        pmc.clear_for_testing();
 | 
			
		||||
        user_topics.set_muted_topics([]);
 | 
			
		||||
        user_topics.set_user_topics([]);
 | 
			
		||||
        muted_users.set_muted_users([]);
 | 
			
		||||
        people.initialize_current_user(15);
 | 
			
		||||
        f({override});
 | 
			
		||||
 
 | 
			
		||||
@@ -57,7 +57,7 @@ function test_notifiable_count(home_unread_messages, expected_notifiable_count)
 | 
			
		||||
function test(label, f) {
 | 
			
		||||
    run_test(label, (helpers) => {
 | 
			
		||||
        unread.declare_bankruptcy();
 | 
			
		||||
        user_topics.set_muted_topics([]);
 | 
			
		||||
        user_topics.set_user_topics([]);
 | 
			
		||||
        f(helpers);
 | 
			
		||||
    });
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user