Skip to content

redefined attr_writer in console_prompt.rb #73

Open
@davebytemfg

Description

@davebytemfg

Now I'm just being pedantic probably because the writer is defined already

      def current_input_str=(str)
diff --git a/dragon/console_prompt.rb b/dragon/console_prompt.rb
index b97bdba..5428254 100644
--- a/dragon/console_prompt.rb
+++ b/dragon/console_prompt.rb
@@ -11,7 +11,8 @@ module GTK
       # ? Can be changed, it was just taken from my editor settings :>
       WORD_LIMITER_CHARS = "`~!@#$%^&*-=+()[]{}\|;:'\",.<>/?_ \t\n\0".chars
 
-      attr_accessor :current_input_str, :font_style, :console_text_width, :last_input_str, :last_input_str_changed
+      attr_accessor :font_style, :console_text_width, :last_input_str, :last_input_str_changed
+      attr_reader :current_input_str
 
       def initialize(font_style:, text_color:, console_text_width:)
         @prompt = '-> '
@@ -71,14 +72,14 @@ module GTK
         return if @cursor_position.zero?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions